Showing 4,939 of 4,939 total issues

Avoid too many return statements within this method.
Open

                return static::astDeclFunction(
                    $n->byRefToken !== null,
                    static::tokenToString($name),
                    static::phpParserParamsToAstParams($n->parameters, $start_line),
                    $ast_return_type,
Severity: Major
Found in src/Phan/AST/TolerantASTConverter/TolerantASTConverter.php - About 30 mins to fix

    Avoid too many return statements within this method.
    Open

                        return new ast\Node(ast\AST_TRAIT_PRECEDENCE, 0, $children, $start_line);
    Severity: Major
    Found in src/Phan/AST/TolerantASTConverter/TolerantASTConverter.php - About 30 mins to fix

      Avoid too many return statements within this method.
      Open

                      return static::astNodeWhile(
                          static::phpParserNodeToAstNode($n->expression),
                          // @phan-suppress-next-line PhanTypeMismatchArgumentNullable return_null_on_empty is false.
                          static::phpParserStmtlistToAstNode($n->statements, $start_line, false),
                          $start_line
      Severity: Major
      Found in src/Phan/AST/TolerantASTConverter/TolerantASTConverter.php - About 30 mins to fix

        Avoid too many return statements within this method.
        Open

                            return $statement;
        Severity: Major
        Found in src/Phan/AST/TolerantASTConverter/TolerantASTConverter.php - About 30 mins to fix

          Avoid too many return statements within this method.
          Open

                          return $inner_node;
          Severity: Major
          Found in src/Phan/AST/TolerantASTConverter/TolerantASTConverter.php - About 30 mins to fix

            Avoid too many return statements within this method.
            Open

                            return static::phpParserThrowToASTThrow($n, $start_line);
            Severity: Major
            Found in src/Phan/AST/TolerantASTConverter/TolerantASTConverter.php - About 30 mins to fix

              Avoid too many return statements within this method.
              Open

                              return new ast\Node(
                                  ast\AST_USE_TRAIT,
                                  0,
                                  [
                                      'traits' => static::phpParserNameListToAstNameList($n->traitNameList->children ?? [], $start_line),
              Severity: Major
              Found in src/Phan/AST/TolerantASTConverter/TolerantASTConverter.php - About 30 mins to fix

                Avoid too many return statements within this method.
                Open

                                    return null;
                Severity: Major
                Found in src/Phan/AST/TolerantASTConverter/TolerantASTConverter.php - About 30 mins to fix

                  Avoid too many return statements within this method.
                  Open

                                              return new ast\Node(
                                                  ast\AST_MAGIC_CONST,
                                                  self::MAGIC_CONST_LOOKUP[\strtoupper($imploded_parts)],
                                                  [],
                                                  self::getStartLine($part)
                  Severity: Major
                  Found in src/Phan/AST/TolerantASTConverter/TolerantASTConverter.php - About 30 mins to fix

                    Avoid too many return statements within this method.
                    Open

                                            return \hexdec($text);
                    Severity: Major
                    Found in src/Phan/AST/TolerantASTConverter/TolerantASTConverter.php - About 30 mins to fix

                      Avoid too many return statements within this method.
                      Open

                                      return static::phpParserClassConstToAstNode($n, $start_line);
                      Severity: Major
                      Found in src/Phan/AST/TolerantASTConverter/TolerantASTConverter.php - About 30 mins to fix

                        Avoid too many return statements within this method.
                        Open

                                        return [self::normalizeTryStatement($node)];
                        Severity: Major
                        Found in src/Phan/AST/ASTSimplifier.php - About 30 mins to fix

                          Avoid too many return statements within this method.
                          Open

                                          return new ast\Node(
                                              $kind,
                                              0,
                                              $children,
                                              $start_line
                          Severity: Major
                          Found in src/Phan/AST/TolerantASTConverter/TolerantASTConverter.php - About 30 mins to fix

                            Avoid too many return statements within this method.
                            Open

                                            return self::phpParserMatchToAstMatch($n, $start_line);
                            Severity: Major
                            Found in src/Phan/AST/TolerantASTConverter/TolerantASTConverter.php - About 30 mins to fix

                              Avoid too many return statements within this method.
                              Open

                                              return \count($stmts) === 1 ? $stmts[0] : $stmts;
                              Severity: Major
                              Found in src/Phan/AST/TolerantASTConverter/TolerantASTConverter.php - About 30 mins to fix

                                Avoid too many return statements within this method.
                                Open

                                                return null;
                                Severity: Major
                                Found in src/Phan/AST/TolerantASTConverter/TolerantASTConverter.php - About 30 mins to fix

                                  Avoid too many return statements within this method.
                                  Open

                                                  return static::newAstDecl(
                                                      ast\AST_METHOD,
                                                      static::phpParserVisibilityToAstVisibility($n->modifiers) | ($n->byRefToken !== null ? flags\FUNC_RETURNS_REF : 0),
                                                      [
                                                          'params' => static::phpParserParamsToAstParams($n->parameters, $start_line),
                                  Severity: Major
                                  Found in src/Phan/AST/TolerantASTConverter/TolerantASTConverter.php - About 30 mins to fix

                                    Avoid too many return statements within this method.
                                    Open

                                                        return null;
                                    Severity: Major
                                    Found in src/Phan/AST/TolerantASTConverter/TolerantASTConverter.php - About 30 mins to fix

                                      Avoid too many return statements within this method.
                                      Open

                                                      return static::astNodeTry(
                                                          // @phan-suppress-next-line PhanTypeMismatchArgumentNullable return_null_on_empty is false.
                                                          static::phpParserStmtlistToAstNode($n->compoundStatement, $start_line, false), // $n->try
                                                          static::phpParserCatchlistToAstCatchlist($n->catchClauses ?? [], $start_line),
                                                          $finally_clause !== null ? static::phpParserStmtlistToAstNode($finally_clause->compoundStatement, self::getStartLine($finally_clause), false) : null,
                                      Severity: Major
                                      Found in src/Phan/AST/TolerantASTConverter/TolerantASTConverter.php - About 30 mins to fix

                                        Avoid too many return statements within this method.
                                        Open

                                                            return null;
                                        Severity: Major
                                        Found in src/Phan/AST/TolerantASTConverter/TolerantASTConverter.php - About 30 mins to fix
                                          Severity
                                          Category
                                          Status
                                          Source
                                          Language