1/* 2 Title: sys.h 3 4 Copyright (c) 2000-7 5 Cambridge University Technical Services Limited 6 Further development Copyright David C.J. Matthews 2007-12, 2015-16 7 8 This library is free software; you can redistribute it and/or 9 modify it under the terms of the GNU Lesser General Public 10 License version 2.1 as published by the Free Software Foundation. 11 12 This library is distributed in the hope that it will be useful, 13 but WITHOUT ANY WARRANTY; without even the implied warranty of 14 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 15 Lesser General Public License for more details. 16 17 You should have received a copy of the GNU Lesser General Public 18 License along with this library; if not, write to the Free Software 19 Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA 20 21*/ 22 23#ifndef _SYS_H 24#define _SYS_H 25 26#define EXC_interrupt 1 /* SML90.Interrupt */ 27#define EXC_syserr 2 /* System call failed. */ 28/* EXC_size (formerly EXC_range) is raised in a number of places, 29 most particularly in alloc_store when given a length which is 30 too large. As "Size" it is used extensively in the Basis library. */ 31#define EXC_size 4 /* General.Size */ 32#define EXC_overflow 5 /* General.Overflow */ 33#define EXC_underflow 6 /* This does not correspond to any ML exception. */ 34#define EXC_divide 7 /* General.Div */ 35#define EXC_conversion 8 36/* 37 EXC_conversion is used within the compiler and by conversion routines 38 added by the compiler in order to signal failure of conversion. 39*/ 40#define EXC_XWindows 10 41/* EXC_subscript is raised both by the string subscript function and 42 also by substring. As "Subscript" it is used extensively in the 43 Basis library. */ 44#define EXC_subscript 11 /* General.Subscript */ 45 46#define EXC_thread 12 /* Thread.Thread. */ /* DCJM 13/3/07 */ 47 48#define EXC_extrace 13 // Used for exception tracing 49 50#define EXC_foreign 23 /* nic 4/5/94 */ 51 52#define EXC_Fail 103 /* DCJM 11/5/06 */ 53// Make sure to add any additional exceptions to make_exn. 54 55#endif 56 57