Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/6.0'
Browse files Browse the repository at this point in the history
Change-Id: Id17896d24f2b6cb0f9b8345188f6d75f42a4ede8
  • Loading branch information
Antoine ELIAS authored and Paul BIGNIER committed Mar 4, 2017
2 parents 3a005b9 + 3bd106a commit c7c3506
Show file tree
Hide file tree
Showing 224 changed files with 2,314 additions and 5,193 deletions.
13 changes: 11 additions & 2 deletions scilab/CHANGES.md
@@ -1,7 +1,7 @@
Welcome to Scilab 6.1.X
=======================

This file details the changes between Scilab 6.1.X (this development branch), and the previous release 6.0.0.
This file details the changes between Scilab 6.1.X (this development branch), and the previous release 6.0.X.
For changelogs of earlier releases, please see [Scilab 6.0.0](https://help.scilab.org/docs/6.0.0/en_US/CHANGES.html).

This file is intended for the specific needs of advanced users, and describes:
Expand Down Expand Up @@ -105,6 +105,15 @@ Bug Fixes

### Bugs fixed in 6.1.0:
* [#14604](http://bugzilla.scilab.org/show_bug.cgi?id=14604): `emptystr()` is 40x slower with 6.0.0 wrt 5.5.2
* [#14605](http://bugzilla.scilab.org/show_bug.cgi?id=14605) fixed - `bench_run` was too strict about the specification of tests names.
* [#14605](http://bugzilla.scilab.org/show_bug.cgi?id=14605): fixed - `bench_run` was too strict about the specification of tests names.
* [#14812](http://bugzilla.scilab.org/show_bug.cgi?id=14812): Minor typos in messages.

### Bugs fixed in 6.0.1:
* [#4276](http://bugzilla.scilab.org/show_bug.cgi?id=4276): `strsubst` replaced the first occurence in regex mode.
* [#5278](http://bugzilla.scilab.org/show_bug.cgi?id=5278): obsolete `xset()` was still used in scripts, macros, tests and help pages.
* [#14636](http://bugzilla.scilab.org/show_bug.cgi?id=14636): Xcos model with modelica electrical blocks (created in 5.5.2) crashed Scilab 6.
* [#14637](http://bugzilla.scilab.org/show_bug.cgi?id=14367): Some Scilab 5.5.2 diagrams didn't simulate properly in Xcos.
* [#14978](http://bugzilla.scilab.org/show_bug.cgi?id=15006): ode help page still contained 'root' which has been replaced by 'roots'.
* [#15010](http://bugzilla.scilab.org/show_bug.cgi?id=15010): Coselica did not simulate on Scilab 6.
* [#15023](http://bugzilla.scilab.org/show_bug.cgi?id=15023): `clf()` wrongly reset `figure_id`.

2 changes: 0 additions & 2 deletions scilab/modules/api_scilab/src/cpp/api_stack_common.cpp
Expand Up @@ -519,8 +519,6 @@ SciErr getVarType(void *_pvCtx, int *_piAddress, int *_piType)
*_piType = sci_strings;
break;
case types::InternalType::ScilabMacroFile :
*_piType = sci_u_function;
break;
case types::InternalType::ScilabMacro :
*_piType = sci_c_function;
break;
Expand Down
13 changes: 12 additions & 1 deletion scilab/modules/api_scilab/src/cpp/api_stack_list.cpp
Expand Up @@ -23,6 +23,7 @@
#include "listundefined.hxx"
#include "tlist.hxx"
#include "mlist.hxx"
#include "struct.hxx"
#include "pointer.hxx"
#include "polynom.hxx"
#include "gatewaystruct.hxx"
Expand Down Expand Up @@ -102,13 +103,23 @@ SciErr getListItemNumber(void* _pvCtx, int* _piAddress, int* _piNbItem)
return sciErr;
}

types::InternalType* pIT = (types::InternalType*)_piAddress;
types::List* pL = (types::List*)_piAddress;
switch (iType)
{
case sci_list :
case sci_mlist :
case sci_tlist :
*_piNbItem = pL->getSize();
case sci_mlist :
// an mlist can also be a struct in Scilab 5 do not manage it in this API
if (pIT->isStruct())
{
*_piNbItem = 0;
}
else
{
*_piNbItem = pL->getSize();
}
break;
default :
addErrorMessage(&sciErr, API_ERROR_INVALID_LIST_TYPE, _("%s: Invalid argument type, %s expected"), "getListItemNumber", _("list"));
Expand Down
2 changes: 0 additions & 2 deletions scilab/modules/api_scilab/src/cpp/template/api_common.hpp
Expand Up @@ -84,8 +84,6 @@ int API_PROTO(getType)(scilabEnv env, scilabVar var)
return sci_strings;
break;
case types::InternalType::ScilabMacroFile:
return sci_u_function;
break;
case types::InternalType::ScilabMacro:
return sci_c_function;
break;
Expand Down
18 changes: 9 additions & 9 deletions scilab/modules/ast/src/cpp/operations/types_and.cpp
Expand Up @@ -413,28 +413,28 @@ InternalType* GenericShortcutAnd(InternalType* _pL)
isValueFalse(_pL->getAs<Int8>(), (Bool**)&pResult);
break;
case InternalType::ScilabUInt8 :
isValueFalse(_pL->getAs<Int8>(), (Bool**)&pResult);
isValueFalse(_pL->getAs<UInt8>(), (Bool**)&pResult);
break;
case InternalType::ScilabInt16 :
isValueFalse(_pL->getAs<Int8>(), (Bool**)&pResult);
isValueFalse(_pL->getAs<Int16>(), (Bool**)&pResult);
break;
case InternalType::ScilabUInt16 :
isValueFalse(_pL->getAs<Int8>(), (Bool**)&pResult);
isValueFalse(_pL->getAs<UInt16>(), (Bool**)&pResult);
break;
case InternalType::ScilabInt32 :
isValueFalse(_pL->getAs<Int8>(), (Bool**)&pResult);
isValueFalse(_pL->getAs<Int32>(), (Bool**)&pResult);
break;
case InternalType::ScilabUInt32 :
isValueFalse(_pL->getAs<Int8>(), (Bool**)&pResult);
isValueFalse(_pL->getAs<UInt32>(), (Bool**)&pResult);
break;
case InternalType::ScilabInt64 :
isValueFalse(_pL->getAs<Int8>(), (Bool**)&pResult);
isValueFalse(_pL->getAs<Int64>(), (Bool**)&pResult);
break;
case InternalType::ScilabUInt64 :
isValueFalse(_pL->getAs<Int8>(), (Bool**)&pResult);
isValueFalse(_pL->getAs<UInt64>(), (Bool**)&pResult);
break;
case InternalType::ScilabSparse :
isValueFalse(_pL->getAs<SparseBool>(), (Bool**)&pResult);
isValueFalse(_pL->getAs<Sparse>(), (Bool**)&pResult);
break;
case InternalType::ScilabSparseBool :
isValueFalse(_pL->getAs<SparseBool>(), (Bool**)&pResult);
Expand Down Expand Up @@ -473,7 +473,7 @@ void isValueFalse(Double* _pL, Bool** _pOut)
if (_pL->isEmpty())
{
//call non shorcut operation
*_pOut = NULL;
*_pOut = new Bool(0); //[] && something -> false
return;
}

Expand Down
16 changes: 8 additions & 8 deletions scilab/modules/ast/src/cpp/operations/types_or.cpp
Expand Up @@ -415,28 +415,28 @@ InternalType* GenericShortcutOr(InternalType* _pL)
isValueTrue(_pL->getAs<Int8>(), (Bool**)&pResult);
break;
case InternalType::ScilabUInt8 :
isValueTrue(_pL->getAs<Int8>(), (Bool**)&pResult);
isValueTrue(_pL->getAs<UInt8>(), (Bool**)&pResult);
break;
case InternalType::ScilabInt16 :
isValueTrue(_pL->getAs<Int8>(), (Bool**)&pResult);
isValueTrue(_pL->getAs<Int16>(), (Bool**)&pResult);
break;
case InternalType::ScilabUInt16 :
isValueTrue(_pL->getAs<Int8>(), (Bool**)&pResult);
isValueTrue(_pL->getAs<UInt16>(), (Bool**)&pResult);
break;
case InternalType::ScilabInt32 :
isValueTrue(_pL->getAs<Int8>(), (Bool**)&pResult);
isValueTrue(_pL->getAs<Int32>(), (Bool**)&pResult);
break;
case InternalType::ScilabUInt32 :
isValueTrue(_pL->getAs<Int8>(), (Bool**)&pResult);
isValueTrue(_pL->getAs<UInt32>(), (Bool**)&pResult);
break;
case InternalType::ScilabInt64 :
isValueTrue(_pL->getAs<Int8>(), (Bool**)&pResult);
isValueTrue(_pL->getAs<Int64>(), (Bool**)&pResult);
break;
case InternalType::ScilabUInt64 :
isValueTrue(_pL->getAs<Int8>(), (Bool**)&pResult);
isValueTrue(_pL->getAs<UInt64>(), (Bool**)&pResult);
break;
case InternalType::ScilabSparse :
isValueTrue(_pL->getAs<SparseBool>(), (Bool**)&pResult);
isValueTrue(_pL->getAs<Sparse>(), (Bool**)&pResult);
break;
case InternalType::ScilabSparseBool :
isValueTrue(_pL->getAs<SparseBool>(), (Bool**)&pResult);
Expand Down

0 comments on commit c7c3506

Please sign in to comment.