Hi guys, i have one more question for you guys…
I asked some friends about this but none can actually give me a fine explanation.
[spoiler]Neither google.[/spoiler]
Whats the difference of lexic, semantic, syntatic analyzers during compilation? I mean, i know what each one does but, suppose i have these codes :
Code A
public void codeA()
{
float a = 10;
String b = "Andre";
double x = a + b;
}
For me its a semantic issue, due to different types.Then again, would lexic and syntatic compilers complain ? i mean, i think they must be more intelligent than theory describes…Isnt it?
Code B
public void codeB(X)
{
String aa = 10;
double float x = 10;
}
Now the code above is very confusing to me.
In my understanding, lexic analyzer would complain of X and syntatic would complain of double float but not of X ?
PS : Thats why practice the theory is important, i know the theory but didnt practice.Please help :persecutioncomplex:
Also, can the three different analyzers complain of the same thing or when 1 complains, it will automatically break the compilation?