[Nice-commit] Nice/src/nice/tools/code Types.java,1.48,1.49
Brought to you by:
bonniot
From: <ar...@us...> - 2003-05-24 14:16:57
|
Update of /cvsroot/nice/Nice/src/nice/tools/code In directory sc8-pr-cvs1:/tmp/cvs-serv5875/F:/nice/src/nice/tools/code Modified Files: Types.java Log Message: Fix the replacement of @type with @any patterns, it should only happen in case of a notnull domain. Index: Types.java =================================================================== RCS file: /cvsroot/nice/Nice/src/nice/tools/code/Types.java,v retrieving revision 1.48 retrieving revision 1.49 diff -C2 -d -r1.48 -r1.49 *** Types.java 17 Mar 2003 20:11:41 -0000 1.48 --- Types.java 24 May 2003 14:16:53 -0000 1.49 *************** *** 608,616 **** ****************************************************************/ ! static boolean isMaybe(Monotype m) { // This is prob. laxist, since getTC() might be different but equivalent to maybeTC (?) return (m instanceof MonotypeConstructor) && ((MonotypeConstructor) m).getTC() == PrimitiveType.maybeTC; } --- 608,623 ---- ****************************************************************/ ! public static boolean isMaybe(Monotype m) { // This is prob. laxist, since getTC() might be different but equivalent to maybeTC (?) return (m instanceof MonotypeConstructor) && ((MonotypeConstructor) m).getTC() == PrimitiveType.maybeTC; + } + + public static boolean isSure(Monotype m) + { + // see comment by isMaybe (e?) + return (m instanceof MonotypeConstructor) + && ((MonotypeConstructor) m).getTC() == PrimitiveType.sureTC; } |