tokens with unicode characters

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

tokens with unicode characters

Bauer, Thomas
Hi There,

i fail to recognize a token like '°'. grammatica's token test outputs "unexpected character '┬'". I tried

%header%
%tokens%
DEGREE                    = <<\u00B0>>
%productions%

but this does not work. Any ideas?

regards
Thomas

_______________________________________________
Grammatica-users mailing list
[hidden email]
https://lists.nongnu.org/mailman/listinfo/grammatica-users
Reply | Threaded
Open this post in threaded view
|

Re: tokens with unicode characters

Per Cederberg
Not at my computer right now, but have you tried editing the grammar file as UTF-8 and defining the token as:

DEGREE = "°"

Could also be that Java on your computer uses a different encoding from your test file... Come to think of it, that's probably it. 

Cheers,

/Per

Den tisdagen den 22:e januari 2013 skrev Bauer, Thomas:
Hi There,

i fail to recognize a token like '°'. grammatica's token test outputs "unexpected character '┬'". I tried

%header%
%tokens%
DEGREE                    = <<\u00B0>>
%productions%

but this does not work. Any ideas?

regards
Thomas

_______________________________________________
Grammatica-users mailing list
[hidden email]
https://lists.nongnu.org/mailman/listinfo/grammatica-users