1
0
mirror of https://git.FreeBSD.org/src.git synced 2024-12-14 10:09:48 +00:00

(Hopefully) make all necessary changes for ficl to support alpha.

This commit is contained in:
Daniel C. Sobral 1999-11-23 11:17:37 +00:00
parent 494b6f4cba
commit 99915e5b91
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=53633
5 changed files with 18 additions and 6 deletions

View File

@ -248,7 +248,11 @@ typedef struct
** machine. 3 would be appropriate for a 64 bit machine.
*/
#if !defined FICL_ALIGN
#if defined __i386__
#define FICL_ALIGN 2
#elif defined __alpha__
#define FICL_ALIGN 4
#endif
#define FICL_ALIGN_ADD ((1 << FICL_ALIGN) - 1)
#endif

View File

@ -248,7 +248,11 @@ typedef struct
** machine. 3 would be appropriate for a 64 bit machine.
*/
#if !defined FICL_ALIGN
#if defined __i386__
#define FICL_ALIGN 2
#elif defined __alpha__
#define FICL_ALIGN 4
#endif
#define FICL_ALIGN_ADD ((1 << FICL_ALIGN) - 1)
#endif

View File

@ -248,7 +248,11 @@ typedef struct
** machine. 3 would be appropriate for a 64 bit machine.
*/
#if !defined FICL_ALIGN
#if defined __i386__
#define FICL_ALIGN 2
#elif defined __alpha__
#define FICL_ALIGN 4
#endif
#define FICL_ALIGN_ADD ((1 << FICL_ALIGN) - 1)
#endif

View File

@ -161,7 +161,7 @@ static void ficlLoad(FICL_VM *pVM)
** any pending REFILLs (as required by FILE wordset)
*/
pVM->sourceID.i = -1;
ficlExec(pVM, "", 0);
ficlExec(pVM, "");
pVM->sourceID = id;
fclose(fp);
@ -271,14 +271,14 @@ void buildTestInterface(void)
int main(int argc, char **argv)
{
char in[nINBUF];
char in[256];
FICL_VM *pVM;
ficlInitSystem(10000);
buildTestInterface();
pVM = ficlNewVM();
ficlExec(pVM, ".ver .( " __DATE__ " ) cr quit", -1);
ficlExec(pVM, ".ver .( " __DATE__ " ) cr quit");
/*
** load file from cmd line...
@ -286,7 +286,7 @@ int main(int argc, char **argv)
if (argc > 1)
{
sprintf(in, ".( loading %s ) cr load %s\n cr", argv[1], argv[1]);
ficlExec(pVM, in, -1);
ficlExec(pVM, in);
}
for (;;)
@ -294,7 +294,7 @@ int main(int argc, char **argv)
int ret;
if (fgets(in, sizeof(in) - 1, stdin) == NULL)
break;
ret = ficlExec(pVM, in, -1);
ret = ficlExec(pVM, in);
if (ret == VM_USEREXIT)
{
ficlTermSystem();

View File

@ -1086,7 +1086,7 @@ static void ifParen(FICL_VM *pVM)
}
else
{ /* take branch (to else/endif/begin) */
vmBranchRelative(pVM, (int)(*pVM->ip));
vmBranchRelative(pVM, *(int*)(pVM->ip));
}
return;