fatso
answered Nov 30 '-1 00:00
#import is like include once . means it will include file only one time in program life
#import "classic_lib.h" means its will load classic_lib only once in time in program life.
it means if you #include "class_lib.h" more than one time in program compiler will generate error ,
and if you put #import "class_lib.h" more than one time in program than compiler will not generate error . but simply ignore it to import it second time.
please Note :: #include "swift_imporver.h" two time not give you error but it included function and code give you error suppose like if swift_imporver.h have function swift_imporver , when it include second time and try to initialize same function again . it give error .
[b]in objective C it means #import , skip second import of same file and include really include rather less it second time or first of time of that file , include will not skip it./b]
to avoid error by include "class.h"( including same file multiple time) , put usual header gards (#ifndef FILE_NAME_H #define FILE_NAME_H #end) so it will not generate error .