Problem with including foreign characters in Lex rule


 
Thread Tools Search this Thread
Top Forums Programming Problem with including foreign characters in Lex rule
# 1  
Old 01-31-2008
Problem with including foreign characters in Lex rule

Hi,

I'm hoping that someone might be able to help me with this problem:

I have already added new code to several existing Lex rules to accept the following foreign characters: å ä ö Å Ä Ö æ Æ ø Ø ü Ü ß. The code looks like this:

/*Nathalie Stern, 080121 - Add å ä ö Å Ä Ö æ Æ ø Ø ü Ü ß handling to function*/
<INITIAL>[A-Za-z]+[A-Za-z0-9_\-\xe5\xe4\xf6\xc5\xc4\xd6\xe6\xc6\xf8\xd8\xfc\xdc\xdf]* {
strcpy(ident1, yytext);
strcpy(latestIdent, yytext);
BEGIN SECID1;
}

Everything compiles and runs fine until I try to include the same character handling in the first part of a rule which checks the first letter of a word being sent in (i.e. in the [A-Za-z]+ part) For some reason, my compiler (Microsoft Visual C++ 6.0) doesn't like it and throws the following error:

Compiling...
lex.tracks.c
Linking...
LINK : warning LNK4098: defaultlib "LIBC" conflicts with use of other libs; use /NODEFAULTLIB:library
tracks1.obj : error LNK2001: unresolved external symbol _tracksMain
.\Debug\simtrac_pre_.exe : fatal error LNK1120: 1 unresolved externals
Error executing link.exe.

simtrac_pre_.exe - 2 error(s), 1 warning(s)

Does anyone have any idea why this happens? I have tried running the clean commando and rebuild and relink all files but I still get the exact same error.
Any thoughts on this would be much appreciated.

Thanks,
Nathalie
# 2  
Old 01-31-2008
Fixed it! The problem was insufficient buffer memory.

Cheers,
Nathalie
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. Linux

iptables rule problem

Hi, i have 40 client's in my network, that connected to internet via squid server (WebProxy). i want none of these client can't ping my squid server bat squid server can ping them.i wrote these rules but it is'nt work. iptables -P INPUT DROP iptables -P OUTPUT DROP iptables -A INPUT -p... (1 Reply)
Discussion started by: skynet_boy
1 Replies

2. Shell Programming and Scripting

sed: remove characters between and including 2 strings

I have the following line: 4/23/2010 0:00:38.000: Copying $$3MSYDDC02$I would like to use sed (or similiar) to remove everthing between and including $ that appears in the line so it ends up like this. 4/23/2010 0:00:38.000: Copying 3MSYDDC02I have been trying these but i'm really just... (5 Replies)
Discussion started by: jelloir
5 Replies

3. Shell Programming and Scripting

How to filter only comments while reading a file including line break characters.

How do I filter only comments and still keep Line breaks at the end of the line!? This is one of the common tasks we all do,, How can we do this in a right way..!? I try to ignore empty lines and commented lines using following approach. test.sh # \040 --> SPACE character octal... (17 Replies)
Discussion started by: kchinnam
17 Replies

4. Shell Programming and Scripting

Regexp to match all characters including "?"

Hi everyone, I'm almost tearing my hairs to find a valid regexp which will match EVERY character in a string, including the question mark! Specifically I need to match a string which contains the word (example) "stringtobematched" at the end of it. Everyone would suggest this: ... (4 Replies)
Discussion started by: lycaon
4 Replies

5. Shell Programming and Scripting

Splitting URL request string including escape characters

Hi All, I have a text file containing two fields, the first field holds the website name and the second one holds the rest of the URL (Request part). My requirement is to split the request part based on the characters "=" and "&". The process should also consider the URL escape characters, for... (4 Replies)
Discussion started by: john2022
4 Replies

6. Shell Programming and Scripting

Multiple characters including single quote in delimiter

Hello, I need to replace the comma to something else between the single quote: 1aaa,bbb,'cc,cc','ddd',1 2aaa,bbb,'ccc','d,d',0 to 1aaa,bbb,'cc<comma>cc','ddd',1 2aaa,bbb,'ccc','d<comma>d',0 Can someone help? Thanks. (2 Replies)
Discussion started by: bgirl
2 Replies

7. UNIX for Advanced & Expert Users

foreign characters in flat file

Hey, Is there anyway I anks, Pocha (12 Replies)
Discussion started by: pochaman
12 Replies

8. Shell Programming and Scripting

foreign characters

I have a flat file and have foreign characters in three fields. Can somebody tell me how to get rid of these special characters? It's very urgent because without this my process is failing. Thanks in advance. Angielina (2 Replies)
Discussion started by: angelina
2 Replies

9. UNIX for Advanced & Expert Users

foreign characters

I have a flat file and have foreign characters in three fields. Can somebody tell me how to get rid of these special characters? It's very urgent because without this my process is failing. Thanks in advance. Angielina (1 Reply)
Discussion started by: angelina
1 Replies

10. UNIX for Dummies Questions & Answers

Foreign characters in bash

Hello, I'm trying to type in foreign characters (á, é, í, ñ...) from the bash when doing a Telnet to my UNIX account. So far it only allows me to type in the standard character set (up to ASCII 128). I need this to feed parameters to certains scripts and programs. Thanks! Miguel (4 Replies)
Discussion started by: czerny
4 Replies
Login or Register to Ask a Question