// DIE's signature file
// Author: hypn0 <hypn0@mail.ru>
// http://www.edm2.com/index.php/IBM_PC_Pascal_Compiler
init("compiler", "IBM PC Pascal");

function detect(bShowType, bShowVersion, bShowOptions) {
    if (MSDOS.compareEP("b8....8ed88c06....fa8ed0268b1e....2bd881fb....7e..bb....d1e3")) {
        sVersion = "2.00";
        sOptions = "1984";
        bDetected = true;
    } else if (MSDOS.compareEP("b8....8ed88bd08c06....268b1e....891e....2bd8f7c3....75..b1..d3e3")) {
        sVersion = "2.05";
        sOptions = "1987";
        bDetected = true;
    } else if (MSDOS.compareEP("ba....b4..b0..8cc98ed9cd21")) {
        sVersion = "2.00";
        sOptions = "1984";
        bDetected = true;
    } else if (MSDOS.compareEP("b8....8ed88c06....ba....d1eab9....2bcad1ea")) {
        sVersion = "1.00";
        sOptions = "1981";
        bDetected = true;
    } else if (MSDOS.compareEP("2e8e1e....8cd08cdb2bc3d1e0")) {
        sVersion = "2.02";
        sOptions = "1987";
        bDetected = true;
    }

    _setLang("Pascal", bDetected);
    return result(bShowType, bShowVersion, bShowOptions);
}