BrightScript Debugger> p loc
<Component: roLocalization>
BrightScript Debugger> p loc.GetPluralString
Syntax Error. (runtime error &h02) in $LIVECOMPILE(8)
BrightScript Debugger> p loc.GetLocalizedAsset
Syntax Error. (runtime error &h02) in $LIVECOMPILE(9)
I’m using roLocalization object which should be supported (http://sdkdocs.roku.com/pages/viewpage. … Id=3114060), and is in fact created. But the ifLocalization interface appears to not exist. How can I fix this? I’m on 5.5.
Hm, yeah - BrightScript is funky like that. Depending on your language background, you may expect obj.method (no params) to either call the method (Ruby?) or to return a bound method function (Python):
>>> f = 'abcdefgh'.find
>>> f
<built-in method find of str object at 0x2b9620>
>>> f('d')
3
But it doesn’t - and can’t blame it for it, because BRS is a different language. I suspect there was a complication in implementing this, so instead a runtime error is thrown (notice how this is not the usual flavor of “Syntax Error. (compile error &h02)”).