mirror of
https://develop.openfoam.com/Development/openfoam.git
synced 2025-11-28 03:28:01 +00:00
ENH: improve dictionary parsing behaviour for ill-formed entries (closes #510)
- mostly associated with forgotten quotes around "(abd|def)" ...
- Address different potential problems:
(key) { key1 entry1; }
(key) { key1 entry1; }; // <- Note trailing ';'
(key) entry2;
This commit is contained in:
54
applications/test/dictionary/testDictList
Normal file
54
applications/test/dictionary/testDictList
Normal file
@ -0,0 +1,54 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: plus |
|
||||
| \\ / A nd | Web: www.OpenFOAM.com |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class dictionary;
|
||||
object testDict;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
// Test some parsing
|
||||
|
||||
// #default
|
||||
internalField uniform 10;
|
||||
// #default
|
||||
dimensions [ 0 2 -2 0 0 0 0 ];
|
||||
|
||||
active
|
||||
{
|
||||
type turbulentIntensityKineticEnergyInlet;
|
||||
intensity 0.1;
|
||||
value $internalField;
|
||||
}
|
||||
|
||||
// #inputMode error
|
||||
active
|
||||
{
|
||||
type turbulentIntensityKineticEnergyInlet;
|
||||
intensity 0.1;
|
||||
value 100;
|
||||
}
|
||||
|
||||
(U|k|epsilon|omega)
|
||||
{
|
||||
solver smoothSolver;
|
||||
smoother symGaussSeidel;
|
||||
tolerance 1e-6;
|
||||
relTol 0;
|
||||
}
|
||||
/*
|
||||
;
|
||||
*/
|
||||
|
||||
(rho) smoothSolver
|
||||
|
||||
//OK smoothSolver // <- missing ';' as well
|
||||
|
||||
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
Reference in New Issue
Block a user