home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #26 / NN_1992_26.iso / spool / comp / parallel / 2497 < prev    next >
Encoding:
Text File  |  1992-11-10  |  1.1 KB  |  41 lines

  1. Newsgroups: comp.parallel
  2. Path: sparky!uunet!spool.mu.edu!agate!usenet.ins.cwru.edu!gatech!hubcap!fpst
  3. From: mlevin@husc8.harvard.edu (Michael Levin)
  4. Subject: a question on C* (Connection Machine) syntax
  5. Message-ID: <1992Nov9.221103.17282@husc3.harvard.edu>
  6. Sender: fpst@hubcap.clemson.edu (Steve Stevenson)
  7. Nntp-Posting-Host: husc8.harvard.edu
  8. Organization: Harvard University Science Center
  9. Distribution: usa
  10. Date: 9 Nov 92 22:11:03 EST
  11. Approved: parallel@hubcap.clemson.edu
  12. Lines: 27
  13.  
  14.  
  15.     The following short C* code does not compile. The  error given by
  16. cs is:
  17.  
  18. "x.cs", line 12: bad operand combination for =
  19.  
  20.    the only difference between lines 12 and 10 is that the
  21. pre-declaration of b() has a float as an argument, and  the one for
  22. a() does not. If I change b to take int:plane, it compiles. Why is
  23. this so? The regular C compiler has no problem with it (without the
  24. :plane). If anyone knows what the problem is, please let me know at
  25. mlevin@presto.cs.tufts.edu. 
  26.  
  27. shape [128][128]plane;
  28.  
  29. int:plane a(int:plane p); 
  30. int:plane b(float:plane p);
  31.  
  32. int:plane (*which_funct(s))()
  33. char *s;
  34. {
  35.   if (!stricmp(s,"A"))
  36.     return(a);
  37.   if (!stricmp(s,"B"))
  38.     return(b);
  39. }
  40.  
  41.