Автор: Elliot Levin (elliotlevin@hotmail.com)
Наследование: implements Pinq\Analysis\ITyped
Пример #1
0
 public function __construct(ITypeSystem $typeSystem, $name, $returnType)
 {
     parent::__construct($typeSystem);
     $this->name = $name;
     $this->reflection = new \ReflectionFunction($name);
     $this->returnType = $returnType;
 }
Пример #2
0
 public function __construct(ITypeSystem $typeSystem, $leftOperandType, $operator, $rightOperandType, $returnType)
 {
     parent::__construct($typeSystem);
     $this->leftOperandType = $leftOperandType;
     $this->operator = $operator;
     $this->rightOperandType = $rightOperandType;
     $this->returnType = $returnType;
 }
Пример #3
0
 public function __construct(ITypeSystem $typeSystem, O\IEvaluationContext $evaluationContext)
 {
     parent::__construct($typeSystem);
     $this->evaluationContext = $evaluationContext;
     foreach ($evaluationContext->getVariableTable() as $variable => $value) {
         $this->setExpressionType(O\Expression::variable(O\Expression::value($variable)), $typeSystem->getTypeFromValue($value));
     }
 }
Пример #4
0
 public function __construct(ITypeSystem $typeSystem, $sourceType, $returnType)
 {
     parent::__construct($typeSystem);
     $this->sourceType = $sourceType;
     $this->returnType = $returnType;
 }