From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-wr1-x42d.google.com (mail-wr1-x42d.google.com [IPv6:2a00:1450:4864:20::42d]) by sourceware.org (Postfix) with ESMTPS id A17293858D33 for ; Tue, 10 May 2022 22:32:51 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org A17293858D33 Received: by mail-wr1-x42d.google.com with SMTP id m1so496693wrb.8 for ; Tue, 10 May 2022 15:32:51 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=aRrShwXNIo4gCj6/cIKllFjEiVJf2UHuMkz1707xWIA=; b=D2mbgxaIqMWS9LlzmtIdFrqI5whkeMqorVx3GQnW6+eAeBQMcdZmDq/DXZ3o/IN9OA YzizApBzPeipnSglIJv0y26vWQNW+wnqE5/qPCo5U77olKGgvqNcRO5dcTnfjxGDj1/q lNhRZIBEhqQGoLYvVx5tNj8R7pPp1pgDUuBTyFHDE0cKGMT9YC5/YdGRbEc693xAQbzJ PtTzveZUPHy8RR0+XHvkuJiqBxREaDDCKLX3yqqiPuHlDKFGn1tHwwlalVmQOyv+LkoM i8w29cNc/Z0gzrTKO4UYecUAIWtRRSeZDhnfjyOK2T7d//u28awytr23zTjL4iZac5Eb ykow== X-Gm-Message-State: AOAM531rnR6yBeNSpJce2dQ1uaS8KeH7rzHG5OQKmaKOeYV0abvH3a+Z p4bynFI9y5YdqN66INpGVsiWl3yrzz3Zfttj7Aw= X-Google-Smtp-Source: ABdhPJy7FpU3EWhvSQnG+KoQu6lkWAmeFAIwZ08ZlWcW2+F4/MBc8fwQaJncfs3YzvQSKxQM3CxoVRLGKLIgXni4Vzs= X-Received: by 2002:a05:6000:c7:b0:20a:d8c1:d044 with SMTP id q7-20020a05600000c700b0020ad8c1d044mr20477722wrx.422.1652221970304; Tue, 10 May 2022 15:32:50 -0700 (PDT) MIME-Version: 1.0 References: In-Reply-To: From: Mohamed Atef Date: Wed, 11 May 2022 00:32:38 +0200 Message-ID: Subject: Re: syntax errors To: =?UTF-8?Q?Andr=C3=A9_Coelho?= Cc: gcc@gcc.gnu.org X-Spam-Status: No, score=-0.4 required=5.0 tests=BAYES_00, BODY_8BITS, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, FREEMAIL_ENVFROM_END_DIGIT, FREEMAIL_FROM, HTML_MESSAGE, RCVD_IN_DNSWL_NONE, SPF_HELO_NONE, SPF_PASS, TXREP, T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.4 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on server2.sourceware.org Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Content-Filtered-By: Mailman/MimeDel 2.1.29 X-BeenThere: gcc@gcc.gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gcc mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 10 May 2022 22:32:53 -0000 Because the fixed code may output results that you don't want. int x 5; Should it be int x =3D 5; or int x5; The parsing operation is very hard and takes some time. There is a method called Global correction to implement a compiler that changes the code but besides the reason above it's too costly to implement. Thanks Mohamed =D9=81=D9=8A =D8=A7=D9=84=D8=A3=D8=B1=D8=A8=D8=B9=D8=A7=D8=A1=D8=8C =D9=A1= =D9=A1 =D9=85=D8=A7=D9=8A=D9=88=D8=8C =D9=A2=D9=A0=D9=A2=D9=A2 =D9=A1=D9=A2= :=D9=A2=D9=A0 =D8=B5 Andr=C3=A9 Coelho via Gcc =D9=83=D8=AA=D8=A8: > Hey...if the compiler can check syntax errors...why can't it fixed them? > > > thanks > > > andre coelho > >