Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

indent not working correctly #1

Open
jjttcc opened this issue Jul 3, 2013 · 0 comments
Open

indent not working correctly #1

jjttcc opened this issue Jul 3, 2013 · 0 comments

Comments

@jjttcc
Copy link

jjttcc commented Jul 3, 2013

I don't know if you still have time to maintain these files, but in case you do, I appear to have found a basic problem with the indent logic. I have a test case with a small class file, child2.e. (Code inserted below.) The original version of this file has no indenting - all lines start at column 1. The 2nd version (below) is the result of making all eiffel.vim files on my system unreadable ('chmod 000' - run on the official eiffel.vim files under /usr/share and the version from this repository, installed under $HOME/.vim) and running the '=' command on the entire file (i.e.: gg^M999==^M). This version, unsurprisingly, has very minimal indenting. The last example (below) is the result of running the '=' command on the entire file after making only the eiffel.vim files under $HOME/.vim (the ones installed from this repository) readable - chmod 644. As you can see, the indenting of the two methods (make and do_something_numeric) is not correct.

Feel free to contact me if you need more info or have further questions.

original, unformatted (flush left) version:

class CHILD2

inherit
PARENT
redefine
do_something_numeric
end

create
make

feature
make
do
end

feature

calculation_result: DOUBLE

do_something_numeric(n: DOUBLE)
do
print("cr, n^n: " + calculation_result.out + ", " + (n^n).out + "%N")
calculation_result := n^n + 0.1
ensure then
child_calcresult_gt_1000: calculation_result > 1000
end

end

formatted, but with all eiffel.vim files unreadable (chmod 000 ...):

class CHILD2

inherit
PARENT
redefine
do_something_numeric
end

create
make

feature
make
do
end

feature

calculation_result: DOUBLE

do_something_numeric(n: DOUBLE)
    do
    print("cr, n^n: " + calculation_result.out + ", " + (n^n).out + "%N")
    calculation_result := n^n + 0.1
    ensure then
    child_calcresult_gt_1000: calculation_result > 1000
    end

    end

formatted with current version (from github) of all 3 eiffel.vim files:

class CHILD2

inherit
    PARENT
        redefine
            do_something_numeric
        end

        create
        make

feature
    make
do
end

feature

    calculation_result: DOUBLE

    do_something_numeric(n: DOUBLE)
do
    print("cr, n^n: " + calculation_result.out + ", " + (n^n).out + "%N")
    calculation_result := n^n + 0.1
    ensure then
        child_calcresult_gt_1000: calculation_result > 1000
end

end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant