mailman3.common-lisp.net
Sign In
Sign Up
Sign In
Sign Up
Manage this list
×
Keyboard Shortcuts
Thread View
j
: Next unread message
k
: Previous unread message
j a
: Jump to all threads
j l
: Jump to MailingList overview
2024
September
August
July
June
May
April
March
February
January
2023
December
November
October
September
August
July
June
May
April
March
February
January
2022
December
November
October
September
August
July
June
May
April
March
February
January
2021
December
November
October
September
August
July
June
May
April
March
February
January
2020
December
November
October
September
August
July
June
May
April
March
February
January
2019
December
November
October
September
August
July
June
May
April
March
February
January
2018
December
November
October
September
August
July
June
May
April
March
February
January
2017
December
November
October
September
August
July
June
May
April
March
February
January
2016
December
November
October
September
August
July
June
May
April
March
February
January
2015
December
November
October
September
August
July
June
May
April
March
February
January
2014
December
November
October
September
August
July
June
May
April
March
February
January
2013
December
November
October
September
August
July
June
May
April
March
February
January
2012
December
November
October
September
August
July
June
May
April
March
February
January
2011
December
November
October
September
August
July
June
May
April
March
February
January
2010
December
November
October
September
August
July
June
May
April
March
February
January
2009
December
November
October
September
August
July
June
May
April
March
February
January
2008
December
November
October
September
August
List overview
Download
armedbear-devel
December 2008
----- 2024 -----
September 2024
August 2024
July 2024
June 2024
May 2024
April 2024
March 2024
February 2024
January 2024
----- 2023 -----
December 2023
November 2023
October 2023
September 2023
August 2023
July 2023
June 2023
May 2023
April 2023
March 2023
February 2023
January 2023
----- 2022 -----
December 2022
November 2022
October 2022
September 2022
August 2022
July 2022
June 2022
May 2022
April 2022
March 2022
February 2022
January 2022
----- 2021 -----
December 2021
November 2021
October 2021
September 2021
August 2021
July 2021
June 2021
May 2021
April 2021
March 2021
February 2021
January 2021
----- 2020 -----
December 2020
November 2020
October 2020
September 2020
August 2020
July 2020
June 2020
May 2020
April 2020
March 2020
February 2020
January 2020
----- 2019 -----
December 2019
November 2019
October 2019
September 2019
August 2019
July 2019
June 2019
May 2019
April 2019
March 2019
February 2019
January 2019
----- 2018 -----
December 2018
November 2018
October 2018
September 2018
August 2018
July 2018
June 2018
May 2018
April 2018
March 2018
February 2018
January 2018
----- 2017 -----
December 2017
November 2017
October 2017
September 2017
August 2017
July 2017
June 2017
May 2017
April 2017
March 2017
February 2017
January 2017
----- 2016 -----
December 2016
November 2016
October 2016
September 2016
August 2016
July 2016
June 2016
May 2016
April 2016
March 2016
February 2016
January 2016
----- 2015 -----
December 2015
November 2015
October 2015
September 2015
August 2015
July 2015
June 2015
May 2015
April 2015
March 2015
February 2015
January 2015
----- 2014 -----
December 2014
November 2014
October 2014
September 2014
August 2014
July 2014
June 2014
May 2014
April 2014
March 2014
February 2014
January 2014
----- 2013 -----
December 2013
November 2013
October 2013
September 2013
August 2013
July 2013
June 2013
May 2013
April 2013
March 2013
February 2013
January 2013
----- 2012 -----
December 2012
November 2012
October 2012
September 2012
August 2012
July 2012
June 2012
May 2012
April 2012
March 2012
February 2012
January 2012
----- 2011 -----
December 2011
November 2011
October 2011
September 2011
August 2011
July 2011
June 2011
May 2011
April 2011
March 2011
February 2011
January 2011
----- 2010 -----
December 2010
November 2010
October 2010
September 2010
August 2010
July 2010
June 2010
May 2010
April 2010
March 2010
February 2010
January 2010
----- 2009 -----
December 2009
November 2009
October 2009
September 2009
August 2009
July 2009
June 2009
May 2009
April 2009
March 2009
February 2009
January 2009
----- 2008 -----
December 2008
November 2008
October 2008
September 2008
August 2008
armedbear-devel@common-lisp.net
1 participants
2 discussions
Start a n
N
ew thread
Re: [armedbear-devel] [armedbear-cvs] r11465 - trunk/abcl/src/org/armedbear/lisp
by Erik Huelsmann
21 Dec '08
21 Dec '08
If you're using trunk, you'll need to delete your .abcl files after updating and building this commit: it changes the structure of the .cls files stored in the .abcl files. Bye, Erik. On Sun, Dec 21, 2008 at 11:16 PM, Erik Huelsmann <ehuelsmann(a)common-lisp.net> wrote: > Author: ehuelsmann > Date: Sun Dec 21 22:16:29 2008 > New Revision: 11465 > > Log: > Make clear difference between calling the template evaluator or evaluating the object. (Relates to ClosureTemplateFunction.) > > Modified: > trunk/abcl/src/org/armedbear/lisp/ClosureTemplateFunction.java > trunk/abcl/src/org/armedbear/lisp/CompiledClosure.java > trunk/abcl/src/org/armedbear/lisp/compiler-pass2.lisp > > Modified: trunk/abcl/src/org/armedbear/lisp/ClosureTemplateFunction.java > ============================================================================== > --- trunk/abcl/src/org/armedbear/lisp/ClosureTemplateFunction.java (original) > +++ trunk/abcl/src/org/armedbear/lisp/ClosureTemplateFunction.java Sun Dec 21 22:16:29 2008 > @@ -33,42 +33,62 @@ > > package org.armedbear.lisp; > > -public abstract class ClosureTemplateFunction extends Closure > +public class ClosureTemplateFunction extends Closure > + implements Cloneable > { > + > + public LispObject[] ctx; > + > public ClosureTemplateFunction(LispObject lambdaList) > throws ConditionThrowable > { > super(list2(Symbol.LAMBDA, lambdaList), null); > } > > + public ClosureTemplateFunction setContext(LispObject[] context) > + { > + ctx = context; > + return this; > + } > + > + public ClosureTemplateFunction dup() > + throws CloneNotSupportedException > + { > + return (ClosureTemplateFunction)super.clone(); > + } > + > + > + > + // execute methods have the semantic meaning > + // "evaluate this object" > public final LispObject execute() throws ConditionThrowable > { > - return notImplemented(); > + return _execute(ctx); > } > > public final LispObject execute(LispObject arg) throws ConditionThrowable > { > - return notImplemented(); > + return _execute(ctx); > } > > public final LispObject execute(LispObject first, LispObject second) > throws ConditionThrowable > { > - return notImplemented(); > + return _execute(ctx, first, second); > } > > public final LispObject execute(LispObject first, LispObject second, > LispObject third) > throws ConditionThrowable > { > - return notImplemented(); > + return _execute(ctx, first, second, third); > } > > public final LispObject execute(LispObject first, LispObject second, > LispObject third, LispObject fourth) > throws ConditionThrowable > { > - return notImplemented(); > + return _execute(ctx, first, second, third, fourth); > } > > public final LispObject execute(LispObject first, LispObject second, > @@ -76,7 +96,7 @@ > LispObject fifth) > throws ConditionThrowable > { > - return notImplemented(); > + return _execute(ctx, first, second, third, fourth, fifth); > } > > public final LispObject execute(LispObject first, LispObject second, > @@ -84,7 +104,7 @@ > LispObject fifth, LispObject sixth) > throws ConditionThrowable > { > - return notImplemented(); > + return _execute(ctx, first, second, third, fourth, fifth, sixth); > } > > public final LispObject execute(LispObject first, LispObject second, > @@ -93,7 +113,7 @@ > LispObject seventh) > throws ConditionThrowable > { > - return notImplemented(); > + return _execute(ctx, first, second, third, fourth, fifth, sixth, seventh); > } > > public final LispObject execute(LispObject first, LispObject second, > @@ -102,7 +122,14 @@ > LispObject seventh, LispObject eighth) > throws ConditionThrowable > { > - return notImplemented(); > + return _execute(ctx, first, second, third, fourth, fifth, > + sixth, seventh, eighth); > + } > + > + public final LispObject execute(LispObject[] args) > + throws ConditionThrowable > + { > + return _execute(ctx, args); > } > > private final LispObject notImplemented() throws ConditionThrowable > @@ -110,35 +137,39 @@ > return error(new WrongNumberOfArgumentsException(this)); > } > > + > + // _execute methods have the semantic meaning > + // "evaluate this template with these values" > + > // Zero args. > - public LispObject execute(LispObject[] context) throws ConditionThrowable > + public LispObject _execute(LispObject[] context) throws ConditionThrowable > { > LispObject[] args = new LispObject[0]; > - return execute(context, args); > + return _execute(context, args); > } > > // One arg. > - public LispObject execute(LispObject[] context, LispObject first) > + public LispObject _execute(LispObject[] context, LispObject first) > throws ConditionThrowable > { > LispObject[] args = new LispObject[1]; > args[0] = first; > - return execute(context, args); > + return _execute(context, args); > } > > // Two args. > - public LispObject execute(LispObject[] context, LispObject first, > + public LispObject _execute(LispObject[] context, LispObject first, > LispObject second) > throws ConditionThrowable > { > LispObject[] args = new LispObject[2]; > args[0] = first; > args[1] = second; > - return execute(context, args); > + return _execute(context, args); > } > > // Three args. > - public LispObject execute(LispObject[] context, LispObject first, > + public LispObject _execute(LispObject[] context, LispObject first, > LispObject second, LispObject third) > throws ConditionThrowable > { > @@ -146,11 +177,11 @@ > args[0] = first; > args[1] = second; > args[2] = third; > - return execute(context, args); > + return _execute(context, args); > } > > // Four args. > - public LispObject execute(LispObject[] context, LispObject first, > + public LispObject _execute(LispObject[] context, LispObject first, > LispObject second, LispObject third, > LispObject fourth) > throws ConditionThrowable > @@ -160,11 +191,11 @@ > args[1] = second; > args[2] = third; > args[3] = fourth; > - return execute(context, args); > + return _execute(context, args); > } > > // Five args. > - public LispObject execute(LispObject[] context, LispObject first, > + public LispObject _execute(LispObject[] context, LispObject first, > LispObject second, LispObject third, > LispObject fourth, LispObject fifth) > throws ConditionThrowable > @@ -175,11 +206,11 @@ > args[2] = third; > args[3] = fourth; > args[4] = fifth; > - return execute(context, args); > + return _execute(context, args); > } > > // Six args. > - public LispObject execute(LispObject[] context, LispObject first, > + public LispObject _execute(LispObject[] context, LispObject first, > LispObject second, LispObject third, > LispObject fourth, LispObject fifth, > LispObject sixth) > @@ -192,11 +223,11 @@ > args[3] = fourth; > args[4] = fifth; > args[5] = sixth; > - return execute(context, args); > + return _execute(context, args); > } > > // Seven args. > - public LispObject execute(LispObject[] context, LispObject first, > + public LispObject _execute(LispObject[] context, LispObject first, > LispObject second, LispObject third, > LispObject fourth, LispObject fifth, > LispObject sixth, LispObject seventh) > @@ -210,11 +241,11 @@ > args[4] = fifth; > args[5] = sixth; > args[6] = seventh; > - return execute(context, args); > + return _execute(context, args); > } > > // Eight args. > - public LispObject execute(LispObject[] context, LispObject first, > + public LispObject _execute(LispObject[] context, LispObject first, > LispObject second, LispObject third, > LispObject fourth, LispObject fifth, > LispObject sixth, LispObject seventh, > @@ -230,11 +261,11 @@ > args[5] = sixth; > args[6] = seventh; > args[7] = eighth; > - return execute(context, args); > + return _execute(context, args); > } > > // Arg array. > - public LispObject execute(LispObject[] context, LispObject[] args) > + public LispObject _execute(LispObject[] context, LispObject[] args) > throws ConditionThrowable > { > return notImplemented(); > > Modified: trunk/abcl/src/org/armedbear/lisp/CompiledClosure.java > ============================================================================== > --- trunk/abcl/src/org/armedbear/lisp/CompiledClosure.java (original) > +++ trunk/abcl/src/org/armedbear/lisp/CompiledClosure.java Sun Dec 21 22:16:29 2008 > @@ -53,32 +53,32 @@ > > public LispObject execute() throws ConditionThrowable > { > - return ctf.execute(context); > + return ctf._execute(context); > } > > public LispObject execute(LispObject arg) throws ConditionThrowable > { > - return ctf.execute(context, arg); > + return ctf._execute(context, arg); > } > > public LispObject execute(LispObject first, LispObject second) > throws ConditionThrowable > { > - return ctf.execute(context, first, second); > + return ctf._execute(context, first, second); > } > > public LispObject execute(LispObject first, LispObject second, > LispObject third) > throws ConditionThrowable > { > - return ctf.execute(context, first, second, third); > + return ctf._execute(context, first, second, third); > } > > public LispObject execute(LispObject first, LispObject second, > LispObject third, LispObject fourth) > throws ConditionThrowable > { > - return ctf.execute(context, first, second, third, fourth); > + return ctf._execute(context, first, second, third, fourth); > } > > public LispObject execute(LispObject first, LispObject second, > @@ -86,7 +86,7 @@ > LispObject fifth) > throws ConditionThrowable > { > - return ctf.execute(context, first, second, third, fourth, fifth); > + return ctf._execute(context, first, second, third, fourth, fifth); > } > > public LispObject execute(LispObject first, LispObject second, > @@ -94,7 +94,7 @@ > LispObject fifth, LispObject sixth) > throws ConditionThrowable > { > - return ctf.execute(context, first, second, third, fourth, fifth, sixth); > + return ctf._execute(context, first, second, third, fourth, fifth, sixth); > } > > public LispObject execute(LispObject first, LispObject second, > @@ -103,7 +103,7 @@ > LispObject seventh) > throws ConditionThrowable > { > - return ctf.execute(context, first, second, third, fourth, fifth, sixth, > + return ctf._execute(context, first, second, third, fourth, fifth, sixth, > seventh); > } > > @@ -113,12 +113,12 @@ > LispObject seventh, LispObject eighth) > throws ConditionThrowable > { > - return ctf.execute(context, first, second, third, fourth, fifth, sixth, > + return ctf._execute(context, first, second, third, fourth, fifth, sixth, > seventh, eighth); > } > > public LispObject execute(LispObject[] args) throws ConditionThrowable > { > - return ctf.execute(context, args); > + return ctf._execute(context, args); > } > } > > Modified: trunk/abcl/src/org/armedbear/lisp/compiler-pass2.lisp > ============================================================================== > --- trunk/abcl/src/org/armedbear/lisp/compiler-pass2.lisp (original) > +++ trunk/abcl/src/org/armedbear/lisp/compiler-pass2.lisp Sun Dec 21 22:16:29 2008 > @@ -8939,7 +8939,14 @@ > super) > (*child-p* > (if *closure-variables* > - +lisp-ctf-class+ > + (progn > + (setf execute-method-name > + (setf (method-name execute-method) "_execute")) > + (setf (method-name-index execute-method) > + (pool-name (method-name execute-method))) > + (setf (method-descriptor-index execute-method) > + (pool-name (method-descriptor execute-method))) > + +lisp-ctf-class+) > (if *hairy-arglist-p* > +lisp-compiled-function-class+ > +lisp-primitive-class+))) > @@ -9251,4 +9258,4 @@ > (initialize-p2-handlers) > > > -(provide "COMPILER-PASS2") > \ No newline at end of file > +(provide "COMPILER-PASS2") > > _______________________________________________ > armedbear-cvs mailing list > armedbear-cvs(a)common-lisp.net >
http://common-lisp.net/cgi-bin/mailman/listinfo/armedbear-cvs
>
1
0
0
0
[armedbear-devel] EXTERNAL-FORMAT support r11409 - branches/open-external-format/
by Erik Huelsmann
01 Dec '08
01 Dec '08
With the commit below, there's infrastructure for general streams to do character encoding and generate a specified line-ending style. It behaves like this: * output: '\n' is translated into - '\r' if :EOL-STYLE is :CR - "\r\n" if :EOL-STYLE is :CRLF - '\n' if :EOL-STYLE is :LF, :RAW * input: '\r" is translated to '\n' for :EOL-STYLE :CR "\r\n" is translated to '\n' for :EOL-STYLE :CRLF '\n' untouched for :EOL-STYLE :LF or :RAW As you see we don't detect \r\n, \r, \n all as end-of-lines, recoding them when required. This is inconsistent with what Subversion does; however, I'm modelling our EXTERNAL-FORMAT support after flexi-streams, so, it needs some investigation to see whether we're actually compatible in that area. Bye, Erik. On Mon, Dec 1, 2008 at 12:05 AM, Erik Huelsmann <ehuelsmann(a)common-lisp.net> wrote: > Author: ehuelsmann > Date: Sun Nov 30 23:05:51 2008 > New Revision: 11409 > > Log: > End-of-line translation for generic streams. > > Modified: > branches/open-external-format/src/org/armedbear/lisp/Stream.java > > Modified: branches/open-external-format/src/org/armedbear/lisp/Stream.java > ============================================================================== > --- branches/open-external-format/src/org/armedbear/lisp/Stream.java (original) > +++ branches/open-external-format/src/org/armedbear/lisp/Stream.java Sun Nov 30 23:05:51 2008 > @@ -1760,13 +1760,19 @@ > { > int n = reader.read(); > ++offset; > - if (n == '\r') > - { > - if (interactive && Utilities.isPlatformWindows) > - return _readChar(); > - } > - if (n == '\n') > + if (eolStyle == EolStyle.CRLF && n == '\r') { > + n = _readChar(); > + if (n != '\n') { > + _unreadChar(n); > + return '\r'; > + } > + } > + > + if (n == eolChar) { > ++lineNumber; > + return '\n'; > + } > + > return n; > } > catch (NullPointerException e) > @@ -1793,7 +1799,7 @@ > { > reader.unread(n); > --offset; > - if (n == '\n') > + if (n == eolChar) > --lineNumber; > } > catch (NullPointerException e) > @@ -1841,14 +1847,16 @@ > { > try > { > - writer.write(c); > - if (c == '\n') > - { > - writer.flush(); > - charPos = 0; > - } > - else > + if (c == '\n') { > + if (eolStyle == EolStyle.CRLF) > + writer.write('\r'); > + writer.write(eolChar); > + writer.flush(); > + charPos = 0; > + } else { > + writer.write(c); > ++charPos; > + } > } > catch (NullPointerException e) > { > @@ -1874,6 +1882,13 @@ > { > try > { > + if (eolStyle != EolStyle.RAW) { > + for (int i = start; i++ < end;) > + //###FIXME: the number of writes can be greatly reduced by > + // writing the space between newlines as chunks. > + _writeChar(chars[i]); > + } > + > writer.write(chars, start, end - start); > int index = -1; > for (int i = end; i-- > start;) > @@ -1918,15 +1933,10 @@ > { > try > { > - writer.write(s); > - int index = s.lastIndexOf('\n'); > - if (index < 0) > - charPos += s.length(); > - else > - { > - charPos = s.length() - (index + 1); > - writer.flush(); > - } > + for (int i = 0; i++ < s.length();) > + //###FIXME: the number of writes can be greatly reduced by > + // writing the space between newlines as chunks. > + _writeChar(s.charAt(i)); > } > catch (NullPointerException e) > { > @@ -1935,10 +1945,6 @@ > else > throw e; > } > - catch (IOException e) > - { > - error(new StreamError(this, e)); > - } > } > > /** Writes a string to the underlying stream, appending > @@ -1951,20 +1957,14 @@ > { > try > { > - writer.write(s); > - writer.write('\n'); > - writer.flush(); > - charPos = 0; > + _writeString(s); > + _writeChar('\n'); > } > catch (NullPointerException e) > { > // writer is null > streamNotCharacterOutputStream(); > } > - catch (IOException e) > - { > - error(new StreamError(this, e)); > - } > } > > // Reads an 8-bit byte. > > _______________________________________________ > armedbear-cvs mailing list > armedbear-cvs(a)common-lisp.net >
http://common-lisp.net/cgi-bin/mailman/listinfo/armedbear-cvs
>
1
0
0
0
Results per page:
10
25
50
100
200