Scilab Home page | Wiki | Bug tracker | Forge | Mailing list archives | ATOMS | File exchange
Please login or create an account
Change language to: Français - Português do Brasil - Japanese -
Scilab help >> Scilab > funcprot

funcprot

switch scilab functions protection mode

Calling Sequence

prot=funcprot()
funcprot(prot)

Arguments

prot

integer with possible values 0,1,2

Description

Scilab functions are variable, funcprot allows the user to specify what scilab do when such variables are redefined.

  • If prot==0 nothing special is done

  • If prot==1 scilab issues a warning message when a function is redefined (default mode)

  • If prot==2 scilab issues an error when a function is redefined

Examples

funcprot(1)
deff('[x]=foo(a)','x=a')
deff('[x]=foo(a)','x=a+1')
foo=33
funcprot(0)
deff('[x]=foo(a)','x=a')
deff('[x]=foo(a)','x=a+1')
foo=33

Comments


Add a comment:
Please login to comment this page.

<< format Scilab funptr >>

Consortium Scilab (DIGITEO)
Scilab Enterprises

Copyright (c) 1989-2012 (INRIA)
Copyright (c) 1989-2007 (ENPC)
with contributors
Last updated:
Wed Oct 05 12:09:25 CEST 2011