getfem-commits
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Getfem-commits] (no subject)


From: Yves Renard
Subject: [Getfem-commits] (no subject)
Date: Tue, 5 Feb 2019 03:07:21 -0500 (EST)

branch: master
commit 86a54a32500f7e98554c6daedc35725206e6d5ce
Author: Yves Renard <address@hidden>
Date:   Tue Feb 5 09:07:11 2019 +0100

    minor fixes
---
 src/getfem_generic_assembly_semantic.cc  | 8 ++------
 src/getfem_generic_assembly_workspace.cc | 2 +-
 2 files changed, 3 insertions(+), 7 deletions(-)

diff --git a/src/getfem_generic_assembly_semantic.cc 
b/src/getfem_generic_assembly_semantic.cc
index ad170f5..9f70cc3 100644
--- a/src/getfem_generic_assembly_semantic.cc
+++ b/src/getfem_generic_assembly_semantic.cc
@@ -330,8 +330,7 @@ namespace getfem {
       break;
     case GA_NODE_INTERPOLATE_DERIVATIVE:
       c += 2.321*ga_hash_code(pnode->interpolate_name_der);
-      // No break. The hash code is completed with the next item
-      [[fallthrough]];
+      [[fallthrough]]; // The hash code is completed with the next item
     case GA_NODE_INTERPOLATE_VAL: case GA_NODE_INTERPOLATE_GRAD:
     case GA_NODE_INTERPOLATE_HESS: case GA_NODE_INTERPOLATE_DIVERG:
     case GA_NODE_INTERPOLATE_VAL_TEST: case GA_NODE_INTERPOLATE_GRAD_TEST:
@@ -525,7 +524,6 @@ namespace getfem {
       if (tree.secondary_domain.size() == 0)
         ga_throw_error(pnode->expr, pnode->pos, "Secondary domain used "
                        "in a single domain term.");
-      // continue with what follows
       [[fallthrough]];
     case GA_NODE_INTERPOLATE:
       if (pnode->name.compare("X") == 0) {
@@ -550,7 +548,6 @@ namespace getfem {
         }
         break;
       }
-      // else continue with what follows
       [[fallthrough]];
     case GA_NODE_ELEMENTARY: // and ... case GA_NODE_INTERPOLATE:
     case GA_NODE_XFEM_PLUS:
@@ -2834,7 +2831,6 @@ namespace getfem {
 
     case GA_NODE_INTERPOLATE_FILTER:
       if (!child_0_is_constant) { is_constant = false; break; }
-      // No break intentionally
       [[fallthrough]];
     case GA_NODE_INTERPOLATE_VAL_TEST:
     case GA_NODE_INTERPOLATE_GRAD_TEST:
@@ -4840,7 +4836,7 @@ namespace getfem {
       case GA_DIV: case GA_DOTDIV:
         if (mark1) return false;
         if (mark0) return ga_node_is_affine(child0);
-        [[fallthrough]];
+        return true;
 
       default: GMM_ASSERT1(false, "Unexpected operation. Internal error.");
       }
diff --git a/src/getfem_generic_assembly_workspace.cc 
b/src/getfem_generic_assembly_workspace.cc
index 8d719f4..15cb98e 100644
--- a/src/getfem_generic_assembly_workspace.cc
+++ b/src/getfem_generic_assembly_workspace.cc
@@ -819,7 +819,7 @@ namespace getfem {
             std::string &name1 = tree.root->name_test1;
             std::string &name2 = tree.root->name_test2;
             const std::vector<std::string> vnames1_(1,name1),
-                                           vnames2_(2,name2);
+                                           vnames2_(1,name2);
             const std::vector<std::string> &vnames1
               = variable_group_exists(name1) ? variable_group(name1)
                                              : vnames1_;



reply via email to

[Prev in Thread] Current Thread [Next in Thread]