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

Example class human not working #24

Closed
methuselah-0 opened this issue May 31, 2017 · 3 comments
Closed

Example class human not working #24

methuselah-0 opened this issue May 31, 2017 · 3 comments

Comments

@methuselah-0
Copy link

methuselah-0 commented May 31, 2017

I wrote a file main_menu.sh which used: import lib/* human.sh
and then I added the example usage of human as in the README but it didn't work:

✘ UNCAUGHT EXCEPTION: Method Human.name is not defined.
 ➦ Method Human.name is not defined. [type.sh:161]
 ✘ e="Method $methodName is not defined." throw [type.sh:161]
 ➦ Type::InjectThisResolutionIfNeeded "$type.$method" [type.sh:417]
 local resultString=$(__return_self_and_result=true ➦ Type::ExecuteMethod "$type" "$variableName" "$method" "${params[@]}" || { local falseBool="${__primitive_extension_fingerprint__boolean}:false"; __return_self_and_result=true @return falseBool $variableName; }) [type.sh:435]
 ➦ Type::RunCurrentStack [type.sh:676]
 eval "${__oo__variableMethodPrefix}${variableName}() { ➦ Type::Handle $variableName "$@"; }" [type.sh:119]
 ➦ A04FB7D7594E479B8CD8D90C5014E37A:Mark [main_menu.sh:51]
 ✘ $var:Mark name = 'Mark' [main_menu.sh:51]

Is this a bug or am I misunderstanding how to use this?

GNU bash, version 4.4.12(1)-release (x86_64-unknown-linux-gnu)

@niieani
Copy link
Owner

niieani commented Jun 2, 2017

Hm, something has broken in the latest Bash release :/
Unfortunately I don't have the time to debug right now. :(

@adanielvv
Copy link
Contributor

Yes, there are a few changes to the declare builtin, see http://tiswww.case.edu/php/chet/bash/NEWS

q. The declare builtin no longer displays array variables using the compound
assignment syntax with quotes; that will generate warnings when re-used as
input, and isn't necessary.

@niieani
Copy link
Owner

niieani commented Oct 20, 2017

Fixed by #26 thanks to @danielVV!

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

3 participants