X-Git-Url: https://git.sesse.net/?a=blobdiff_plain;f=lex.c;h=0c8d26f192148e54c1ea5ac32f54587dc29dbfbc;hb=24340f183eef0351ac9b6cfc0aa3d9c1672893b6;hp=3474a15523b27055716617a802e651f593f1bf3f;hpb=f3232c478fb5fd9c1fd6fc767b5c8c8320ab8209;p=pgn-extract diff --git a/lex.c b/lex.c index 3474a15..0c8d26f 100644 --- a/lex.c +++ b/lex.c @@ -1268,3 +1268,8 @@ terminate_input(void) } } + /* Return the position in the current file. Returns -1 if it is unseekable. */ +long get_position(void) +{ + return ftell(yyin); +}