| Bill Allombert on Thu, 07 May 2026 18:41:48 +0200 |
[Date Prev] [Date Next] [Thread Prev] [Thread Next] [Date Index] [Thread Index]
| Re: MAX_ARG_STRLEN |
On Thu, May 07, 2026 at 12:13:43PM -0400, Igor Schein wrote:
> Hi,
>
> I thought I had hit a bug in galoisexport(), but eventually I figured
> out what I was actually hitting was the MAX_ARG_STRLEN limitation when
> passing output of galoisexport() longer than MAX_ARG_STRLEN to an
> external program via extern(). This is just an FYI, in case someone
> else runs into this. I rewrote my tools to use temporary files
> instead, and everything is peachy now.
Note that you can use a pipe now:
? gapident(G)=my(f=fileextern("gap -q","w"));filewrite(f,Str("IdGroup(",galoisexport(G),");\n")); fileclose(f);
? G=galoisinit(polcyclo(48));
? gapident(G)
[ 16, 10 ]
But it does not allow you to capture the result.
Cheers,
Bill.