123456789101112131415161718192021222324252627282930313233343536(******************************************************************************)(* *)(* SPDX-License-Identifier LGPL-2.1 *)(* Copyright (C) *)(* CEA (Commissariat à l'énergie atomique et aux énergies alternatives) *)(* INRIA (Institut National de Recherche en Informatique et en Automatique) *)(* INSA (Institut National des Sciences Appliquees) *)(* *)(******************************************************************************)openLexingletabort_currentlexfmt=letstart_pos=Cil_datatype.Position.of_lexing_pos(lexeme_start_plex)inletend_pos=Cil_datatype.Position.of_lexing_pos(lexeme_end_plex)inletfmt="before or at token %s@\n%a@\n"^^fmtinAorai_option.abortfmt(Lexing.lexemelex)(Errorloc.pp_context_from_file~ctx:2)(start_pos,end_pos)letunknown_tokenlex=abort_currentlex"Unexpected character: '%c'"(lexeme_charlex(lexeme_startlex))letnewlinelexbuf=letpos=lexbuf.lex_curr_pinlexbuf.lex_curr_p<-{poswithpos_lnum=pos.pos_lnum+1;pos_bol=pos.pos_cnum}letunterminated_commentlexbuf=abort_currentlexbuf"Unterminated C comment"