
(* This file was auto-generated based on "parser.messages". *)

(* Please note that the function [message] can raise [Not_found]. *)

let message =
  fun s ->
    match s with
    | 492 | 491 | 490 ->
        "Expected \"[\" expression \"]\" for size of sum_to_zero_vector vector.\n"
    | 500 | 501 | 502 | 503 | 504 ->
        "Expected \"[\" expression \",\" expression \"]\" for size of column_stochastic_matrix.\n"
    | 494 | 495 | 496 | 497 | 498 ->
        "Expected \"[\" expression \",\" expression \"]\" for size of row_stochastic_matrix.\n"
    | 647 | 646 | 622 | 621 | 330 | 329 ->
        "\";\\\" expected after variable declaration.\nIt looks like you are trying to use the old array syntax.\nPlease use the new syntax:\nhttps://mc-stan.org/docs/reference-manual/types.html#array-data-types.section\n"
    | 296 | 295 | 294 | 293 ->
        "Ill-formed fatal error statement. After \"fatal_error(\", we expect a comma separated list of either expressions or strings, followed by \");\".\n"
    | 15 | 14 ->
        "\"[\" (list of commas) \"]\" expected in unsized return type of function definition.\n"
    | 614 | 620 ->
        "\";\" expected after variable declaration.\n"
    | 645 | 321 | 311 | 328 ->
        "\";\" or plain assignment expected after variable declaration.\n"
    | 20 | 3 | 196 | 488 ->
        "Invalid type specification.\nExpected \"(\" followed by further types and \")\" to complete tuple.\n"
    | 603 | 636 | 598 | 304 ->
        "Expected identifier as part of top-level variable declaration.\n"
    | 470 ->
        "Expected \">\" or \", upper = expression>\" (with expression not containing binary logical operators) expected after specifying lower bound for type.\n"
    | 226 ->
        "Expected expressions for size of array.\n"
    | 19 | 239 | 583 ->
        "Expected non-array type after \"array\" declaration.\n"
    | 23 | 22 | 24 | 32 | 33 | 4 | 25 | 21 ->
        "Expected comma-separated list of types followed by \")\" to declare tuple type.\n"
    | 104 | 185 ->
        "Expression or comma separated list of expressions followed by \")\" expected after \"(\".\n"
    | 197 | 489 ->
        "Incomplete type declaration. Expected comma separated list of types between \"(\"\nand \")\" to declare tuple variable.\n"
    | 236 | 580 | 233 | 577 | 231 | 575 ->
        "Incomplete type specification. Expected either \")\" or \",\" followed by\nfurther types and \")\" to complete tuple.\n"
    | 229 | 249 | 573 | 593 | 245 | 589 ->
        "Invalid type specification, unmatched \"(\".\nExpected \",\" followed by further types and \")\" to complete tuple.\n"
    | 250 | 234 | 578 | 232 | 576 | 230 | 237 | 581 | 574 | 594 | 246 | 590 ->
        "Incomplete type specification, expected further types followed by \")\" to complete tuple.\n"
    | 653 | 378 | 627 ->
        "Expected identifier after type in declaration.\n"
    | 227 | 13 | 225 ->
        "Expected \"[\" array sizes \"]\" followed by type after \"array\".\n"
    | 401 ->
        "Only function definitions/declarations are expected in '.stanfunctions' file\n"
    | 0 ->
        "Function definitions/declarations expected in '.stanfunctions' file\n"
    | 560 ->
        "Expected identifier as part of top-level variable declaration.\n"
    | 276 ->
        "Ill-formed phrase. \"{\" should be followed by a statement, variable declaration or expression.\n"
    | 275 ->
        "Expected \"{\" after profile definition.\n"
    | 274 ->
        "Expected \")\" after profile name.\n"
    | 273 ->
        "Expected profile name as string in parenthesis\n"
    | 272 ->
        "Expected profile name as string in parenthesis\n"
    | 313 | 605 | 600 | 306 ->
        "Expected a new identifier after comma in declaration.\nAll variables declared must be of the same type, and any initializing assignment must follow the identifier before the next comma.\n"
    | 628 | 602 | 599 | 606 | 617 ->
        "Cannot assign to variables in the `data` or `parameters` blocks; expected ';'\nafter variable declaration.\n"
    | 467 ->
        "Expected '>' after multiplier expression.\n"
    | 466 ->
        "Numerical expression expected after '=' in a multiplier expression.\n"
    | 465 ->
        "'=' expected after 'multiplier' keyword.\n"
    | 463 | 464 ->
        "Expected '>' or offset expression after multiplier expression.\n"
    | 453 ->
        "Expected '>' after lower expression.\n"
    | 452 ->
        "Numerical expression expected after '=' in a lower expression.\n"
    | 451 ->
        "'=' expected after 'upper' keyword.\n"
    | 450 ->
        "'>' or lower expression expected after upper expression.\n"
    | 667 ->
        "We expect \"{\" after \"transformed parameters\".\n"
    | 668 ->
        "Expect a statement or top-level variable declaration.\n"
    | 672 ->
        "\"model {\" or \"generated quantities {\" expected after end of transformed parameters block.\n"
    | 634 ->
        "We expect \"{\" after \"transformed data\".\n"
    | 96 ->
        "After \"while\", we expect \"(\" expression \")\" statement.\n"
    | 190 | 97 ->
        "Ill-formed expression. We expect an expression after \"(\" for the test of a while-loop.\n"
    | 191 ->
        "Ill-formed statement. We expect a statement after \")\", for the body of the while-loop.\n"
    | 635 ->
        "Expect a statement or top-level variable declaration.\n"
    | 641 ->
        "Ill-formed top-level variable declaration. Expect an identifier next.\n"
    | 374 ->
        "Ill-formed assignment statement. Expected an expression followed by \";\" next.\n"
    | 375 ->
        "Ill-formed assignment statement. Expected a \";\" after the value being assigned.\n"
    | 362 | 359 | 371 | 368 | 356 ->
        "Ill-formed compound assignment statement. Expected an expression followed by \";\" next.\n"
    | 360 | 363 | 369 | 366 | 372 | 357 ->
        "Ill-formed compound assignment statement. Expected a \";\" after the value being assigned.\n"
    | 393 | 338 ->
        "Ill-formed phrase. Found an expression where we expected a statement.\n"
    | 334 | 116 | 335 ->
        "Ill-formed function application. Expect comma-separated list of expressions followed by \")\" after \"(\".\n"
    | 336 ->
        "Ill-formed phrase. Found a well-formed function application. Expected either a \";\" or a valid continuation of the expression.\n"
    | 175 ->
        "Ill-formed conditional distribution evaluation. Expect comma-separated list of expressions followed by \")\" after \"|\".\n"
    | 176 ->
        "Ill-formed conditional distribution evaluation. Expect comma-separated list of expressions followed by \")\" after \"|\".\n"
    | 253 ->
        "Ill-formed phrase. Expect either \"+=\" or \"()\" after \"target\".\n"
    | 254 | 255 ->
        "Ill-formed statement. Expression followed by \";\" expected after \"target +=\".\n"
    | 99 ->
        "Ill-formed expression. Expected \")\" after \"target(\".\n"
    | 258 | 260 ->
        "Ill-formed return statement. \";\" or expression followed by \";\" expected after \"return\".\n"
    | 112 ->
        "Ill-formed expression. In function application, expect comma-separated list of expressions followed by \")\", after \"(\".\n"
    | 114 ->
        "Ill-formed expression. In function application, expect comma-separated list of expressions followed by \")\", after \"(\".\n"
    | 98 ->
        "Ill formed expression. After \"target\", we expect \"()\".\n"
    | 106 ->
        "Expression expected after \"{\" in array expression.\n"
    | 262 | 266 | 271 | 267 | 263 ->
        "Ill-formed reject statement. After \"reject(\", we expect a comma separated list of either expressions or strings, followed by \");\".\n"
    | 269 ->
        "Ill-formed printable. After \"print(\" and \"reject(\", we expect a comma separated list of either expressions or strings, followed by \");\".\n"
    | 270 ->
        "Ill-formed printable. After \"print(\" and \"reject(\", we expect a comma separated list of either expressions or strings, followed by \");\".\n"
    | 339 ->
        "Ill-formed \"~\"-statement. Expect an distribution name after \"~\".\n"
    | 340 ->
        "Ill-formed \"~\"-statement. Expect \"(\" after distribution name, followed by a comma separated list of expressions for arguments to the distribution, followed by \")\".\n"
    | 341 ->
        "Ill-formed \"~\"-statement. Expect a comma separated list of expressions for arguments to the distribution, followed by \")\".\n"
    | 342 ->
        "Ill-formed \"~\"-statement. Expect a comma separated list of expressions for arguments to the distribution, followed by \")\".\n"
    | 343 ->
        "Ill-formed \"~\"-statement. Expect either \";\" or a truncation with the format \"T[\" optional expression \",\" optional expression \"];\".\n"
    | 347 | 348 | 346 | 344 | 350 | 345 ->
        "Ill-formed truncation. Expect the format \"T[\" optional expression \",\" optional expression \"];\".\n"
    | 352 ->
        "Expected \";\" after \"~\"-statement (with optional truncation).\n"
    | 170 | 169 ->
        "Ill-formed expression. Expected expression or \"]\" or \",\" after \":\".\n"
    | 166 ->
        "Expected index after indices followed by \",\".\n"
    | 128 ->
        "Ill-formed expression. Expected expression or \"]\" or \",\" after \":\".\n"
    | 188 | 189 ->
        "Ill-formed expression. Found an expression. Expect an infix or postfix operator or \"[\"\n"
    | 129 ->
        "Ill-formed phrase. Found \":\" expression. We expect either an infix or postfix operator, or \",\" or or \"[\" or \"]\" next.\n"
    | 162 | 147 | 146 ->
        "Found an incomplete ternary expression, should be \"(condition) ? (true branch) : (false branch)\".\nDid you forget to add a colon or a false branch?\nFor example, this returns 3.0:\n  1 ? 0.0 : 3.0\n"
    | 120 | 144 | 132 | 148 | 150 | 134 | 152 | 130 | 118 | 160 | 142 | 140 | 138 | 158 | 156 | 122 | 154 | 365 | 436 | 426 | 136 | 124 ->
        "Found an incomplete binary expression - are you missing the right hand side?\n"
    | 355 | 179 | 111 | 174 | 163 | 125 | 139 | 131 | 119 | 159 | 157 | 123 | 137 | 121 | 155 | 153 | 141 | 161 | 145 | 135 | 151 | 149 | 133 | 143 | 126 | 333 ->
        "Unexpected input after the conclusion of a valid expression.\nYou may be missing a \",\" between expressions, an operator, or a terminating \"}\", \")\", \"]\", or \";\".\n"
    | 660 ->
        "Expected \"parameters {\", \"transformed parameters {\", \"model {\", \"generated quantities {\" or end-of-file after end of transformed data block.\n"
    | 277 ->
        "Expected \"(\" followed by a comma-separated list of expressions or strings followed by \");\" after \"print\".\n"
    | 278 ->
        "Expected a comma-separated list of expressions or strings followed by \");\" after \"print(\".\n"
    | 280 ->
        "Expected a \";\" after \"print(...)\".\n"
    | 279 ->
        "Expected a comma-separated list of expressions or strings followed by \");\" after \"print(\".\n"
    | 102 ->
        "Ill-formed expression. Expect an expression after \"+\".\n"
    | 103 ->
        "Ill-formed expression. Expect an expression after \"-\".\n"
    | 186 | 183 ->
        "Ill-formed phrase. Found \"(\" followed by expression. Expect a \"[\", \",\" or \")\" or an infix or postfix operator.\n"
    | 105 ->
        "Comma separated list of expressions followed by \"]\" expected after \"[\".\n"
    | 127 | 168 | 181 ->
        "Ill-formed expression. We expect a comma separated list of expressions, followed by \"]\".\n"
    | 172 ->
        "Ill-formed expression. We expect a comma separated list of expressions.\n"
    | 282 ->
        "Ill-formed phrase. \"{\" should be followed by a statement, variable declaration or expression.\n"
    | 283 ->
        "\"(\" expression \")\" expected after \"if\".\n"
    | 284 ->
        "Expected expression for test of conditional control flow construct.\n"
    | 285 ->
        "Ill-formed expression. Expression expected after \"(\", for test of conditional control flow construct.\n"
    | 387 ->
        "Ill-formed statement. Expected statement after else.\n"
    | 286 ->
        "Ill-formed statement. Statement expected for true branch of conditional.\n"
    | 640 | 386 ->
        "Ill-formed block. Expected a statement, variable declaration, or just \"}\".\n"
    | 287 ->
        "Expected \"(\" after \"for\".\n"
    | 288 ->
        "Expected (loop) identifier after \"(\".\n"
    | 289 ->
        "Expected \"in\" after loop identifier.\n"
    | 290 | 291 ->
        "Ill-formed expression. Expected expression followed by \")\" or \":\" after \"for (\" identifier \"in\".\n"
    | 292 ->
        "Ill-formed statement. Expected statement after \")\" for the loop body of the foreach loop.\n"
    | 383 | 382 ->
        "Ill-formed expression. Expected expression followed by \")\" after \"for (\" identifier \"in\" expression \":\".\n"
    | 384 ->
        "Ill-formed statement. Expected statement after \")\" for the loop body of the for loop.\n"
    | 298 ->
        "Expected \";\" after \"continue\".\n"
    | 300 ->
        "Expected \";\" after \"break\".\n"
    | 178 | 110 ->
        "Ill-formed expression. Expression expected after \"!\".\n"
    | 661 ->
        "Expected \"{\" after \"parameters\".\n"
    | 662 ->
        "Expected top-level variable declaration or \"}\".\n"
    | 666 ->
        "\"transformed parameters {\", \"model {\" or \"generated quantities {\" expected after end of parameters block.\n"
    | 673 ->
        "Expected \"{\" after \"model\".\n"
    | 674 ->
        "Variable declaration, statement or \"}\" expected.\n"
    | 544 | 546 | 545 | 543 | 212 | 479 | 481 | 480 | 415 | 194 | 211 | 193 | 210 | 192 ->
        "Expected \"[\" expression \"]\" for vector size.\n"
    | 389 ->
        "Variable declaration, statement or \"}\" expected.\n"
    | 512 | 510 | 549 | 551 | 550 | 548 | 216 | 215 | 214 | 513 | 200 | 198 | 199 ->
        "\"[\" expression \"]\" expected for row_vector size.\n"
    | 324 ->
        "Identifier expected after sized type in local (or model block) variable declaration. (No transformations/constraints allowed.)\n"
    | 315 | 314 ->
        "Ill-formed expression. Expression followed by \";\" expected after \"=\".\n"
    | 677 ->
        "Expected \"generated quantities {\" or end of file after end of model block.\n"
    | 526 | 530 | 529 | 528 | 527 | 525 | 554 | 558 | 557 | 556 | 555 | 553 | 222 | 221 | 220 | 219 | 218 | 207 | 206 | 205 | 204 | 203 ->
        "\"[\" expression \",\" expression \"]\" expected for matrix sizes.\n"
    | 678 ->
        "Expected \"{\" after block keyword.\n"
    | 679 ->
        "Variable declaration or statement or \"}\" expected in generated quantities block.\n"
    | 682 ->
        "Expected end of file after end of generated quantities block.\n"
    | 407 ->
        "\"{\" expected after \"functions\".\n"
    | 408 ->
        "Function forward declaration, definition or \"}\" expected after \"functions {\".\n"
    | 37 ->
        "An identifier is expected as a function name.\n"
    | 87 ->
        "\"(\" expected after function name.\n"
    | 398 ->
        "\",\" or \")\" expected after function argument declaration.\n"
    | 88 | 399 ->
        "An argument declaration (unsized and unconstrained type followed by identifier) is expected.\n"
    | 95 ->
        "Either \"{\" statement \"}\" is expected for a function definition or \";\" for a function forward declaration.\n"
    | 92 | 27 | 91 ->
        "An identifier is expected after the type as a function argument name.\n"
    | 409 | 404 ->
        "A \"}\" or a function definition/declaration is expected.\n"
    | 412 ->
        "Expected \"data {\" or \"transformed data {\" or \"parameters {\" or \"transformed parameters {\" or \"model {\" or \"generated quantities {\".\n"
    | 413 ->
        "\"{\" followed by a list of top-level variable declarations is expected after seeing \"data\".\n"
    | 414 ->
        "Invalid type in declaration. Valid types:\n  int, real, vector, row_vector, matrix,\n  unit_vector, simplex, sum_to_zero_vector, ordered, positive_ordered,\n  corr_matrix, cov_matrix, cholesky_factor_corr, cholesky_factor_cov,\n  row_stochastic_matrix, column_stochastic_matrix, tuple(...)\noptionally preceded by a single array[...]\n"
    | 616 ->
        "We expect to see an identifier after a sized type.\n"
    | 416 ->
        "We expect to see \"lower =\", \"upper =\", \"offset =\" or \"multiplier =\" followed by an expression after \"<\".\n"
    | 417 ->
        "Expect \"=\" expression \">\" after seeing \"upper\".\n"
    | 418 ->
        "Expression (not containing binary logical operators) expected after \"upper =\". Ill-formed expression.\n"
    | 432 ->
        "Ill-formed expression. Expected expression (not containing binary logical operators).\n"
    | 438 ->
        "Ill-formed expression. Expected expression (not containing binary logical operators).\n"
    | 440 ->
        "Ill-formed expression. Expected expression (not containing binary logical operators).\n"
    | 448 ->
        "Ill-formed expression. Expected expression (not containing binary logical operators).\n"
    | 434 ->
        "Ill-formed expression. Expected expression (not containing binary logical operators).\n"
    | 424 ->
        "Ill-formed expression. Expected expression (not containing binary logical operators).\n"
    | 442 ->
        "Ill-formed expression. Expected expression (not containing binary logical operators).\n"
    | 444 ->
        "Ill-formed expression. Expected expression (not containing binary logical operators).\n"
    | 446 ->
        "Ill-formed expression. Expected expression (not containing binary logical operators).\n"
    | 419 ->
        "Ill-formed expression. Expected expression (not containing binary logical operators).\n"
    | 420 ->
        "Ill-formed expression. Expected expression (not containing binary logical operators).\n"
    | 428 | 421 ->
        "Ill-formed expression. Expected expression (not containing binary logical operators).\n"
    | 461 ->
        "Expected \"=\" expression (not containing binary logical operators) \">\" after \"multiplier\".\n"
    | 462 ->
        "Expected expression (not containing binary logical operators) after \"multiplier =\".\n"
    | 468 ->
        "Expected \"=\" expression (not containing binary logical operators), after \"lower\".\n"
    | 469 ->
        "An expression (not containing binary logical operators) is expected for type lower bound.\n"
    | 471 ->
        "\"upper =\" expression (not containing binary logical operators) \">\" expected after \"<lower =\" expression \",\" in top-level variable declaration.\n"
    | 472 ->
        "Expected \"=\" expression (not containing binary logical operators) after \"upper\".\n"
    | 422 | 473 ->
        "Expected expression (not containing binary logical operators) after \"upper = \".\n"
    | 447 | 445 | 427 | 443 | 425 | 437 | 435 | 449 | 441 | 439 | 433 | 431 | 430 | 429 | 474 ->
        "Expected \">\" after \"upper = \" expression.\n"
    | 454 ->
        "Expected \"offset = \" expression (not containing binary logical operators).\n"
    | 455 ->
        "Expected \"offset = \" expression (not containing binary logical operators).\n"
    | 456 | 457 ->
        "Expected \">\" or \", multiplier = \" expression (not containing binary logical operators) \">\" after \"offset = \" expression.\n"
    | 458 ->
        "Expected \"multiplier = \" expression (not containing binary logical operators).\n"
    | 459 ->
        "Expected \"multiplier = \" expression (not containing binary logical operators).\n"
    | 460 ->
        "Expected \">\" after \"multiplier = \" expression.\n"
    | 486 | 485 | 484 ->
        "Expected \"[\" expression \"]\" for size of unit_vector.\n"
    | 508 | 507 | 506 ->
        "Expected \"[\" expression \"]\" for size of simplex.\n"
    | 511 ->
        "Expected identifier as part of top-level variable declaration.\n"
    | 515 ->
        "Identifier expected after type in top-level variable declaration.\n"
    | 624 ->
        "Only top-level variable declarations allowed in data and parameters blocks.\n"
    | 633 ->
        "Expected \"transformed data {\" or \"parameters {\" or \"transformed parameters {\" or \"model {\" or \"generated quantities {\".\n"
    | 519 | 518 | 517 ->
        "Expected \"[\" expression \"]\" for size of positive_ordered.\n"
    | 523 | 522 | 521 ->
        "Expected \"[\" expression \"]\" for size of ordered.\n"
    | 532 ->
        "Expected range constraint or identifier as part of top-level variable declaration.\n"
    | 533 ->
        "Expected \"lower = \" expression or \"upper = \" expression for integer bounds.\n"
    | 537 | 536 | 535 ->
        "Expected \"[\" expression \"]\" for size of cov_matrix.\n"
    | 541 | 540 | 539 ->
        "Expected \"[\" expression \"]\" for size of corr_matrix.\n"
    | 566 | 565 | 562 | 564 | 563 ->
        "Expected \"[\" expression \"]\" or \"[\" expression \",\" expression \"]\" for size of cholesky_factor_cov.\n"
    | 571 | 570 | 569 ->
        "Expected \"[\" expression \"]\" for size of cholesky_factor_corr.\n"
    | 406 ->
        "Expected \"functions {\" or \"data {\" or \"transformed data {\" or \"parameters {\" or \"transformed parameters {\" or \"model {\" or \"generated quantities {\".\n"
    | _ ->
        raise Not_found
