~ubuntu-branches/ubuntu/hoary/scilab/hoary

« back to all changes in this revision

Viewing changes to macros/m2sci/kernel/%type_i_variable.sci

  • Committer: Bazaar Package Importer
  • Author(s): Torsten Werner
  • Date: 2005-01-09 22:58:21 UTC
  • mfrom: (1.1.1 upstream)
  • Revision ID: james.westby@ubuntu.com-20050109225821-473xr8vhgugxxx5j
Tags: 3.0-12
changed configure.in to build scilab's own malloc.o, closes: #255869

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
function var=%type_i_variable(field,inslist,var)
 
2
// Copyright INRIA
 
3
 
 
4
if typeof(inslist)=="ce" then
 
5
  if field=="type" then
 
6
    var.infer=inslist
 
7
  else
 
8
    error("Not yet implemented...")
 
9
  end
 
10
elseif typeof(inslist)=="st" then
 
11
  pause
 
12
else
 
13
  if or(typeof(var.infer)==["ce","st"]) then
 
14
    if field=="type" then
 
15
      dims=list()
 
16
      for kd=1:size(var.infer.dims,"*")
 
17
        dims(kd)=var.infer.dims(kd)
 
18
      end
 
19
      var.infer=Infer(dims,Type())
 
20
      var.infer.type=inslist
 
21
    else
 
22
      error("Not yet implemented...")
 
23
    end
 
24
  else 
 
25
    if field=="type" then
 
26
      var.infer.type=inslist
 
27
    else
 
28
      error("Not yet implemented...")
 
29
    end
 
30
  end
 
31
end
 
32
endfunction