You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I would expect the printed accessFun "field" to be
--> ".field"
Is this intentional?
If yes, I suggest using
String.replace "."""
or something similar to make both accessFun "field" and accessFun ".field" return ".field".
Even if it isn't intentional, I'd suggest to using String.replace to make accessFun backwards compatible.
The text was updated successfully, but these errors were encountered:
lue-bird
changed the title
print accessFun field as ".field"
print accessFun "field" as ".field"
Sep 10, 2021
It is intentional because elm-syntax-dsl is a convenience layer on top of stil4m/elm-syntax and that is the way that it works. You can see all it does is invoke the underlying constructor.
At some point this package will move away from stil4m/elm-syntax for various reasons so compatability with it will cease to be an issue.
I think your suggestion of making both ways work is good though, since field names can never begin with '.', doing that will never produce a bad field name.
In the example
I would expect the printed
accessFun "field"
to be--> ".field"
Is this intentional?
If yes, I suggest using
or something similar to make both
accessFun "field"
andaccessFun ".field"
return".field"
.Even if it isn't intentional, I'd suggest to using
String.replace
to makeaccessFun
backwards compatible.The text was updated successfully, but these errors were encountered: