FiveTech Support Forums

FiveWin / Harbour / xBase community
Board index FiveWin para Harbour/xHarbour static function XXX defined but never used?
Posts: 418
Joined: Wed Nov 26, 2008 06:33 PM
static function XXX defined but never used?
Posted: Tue Aug 11, 2020 08:57 PM

Saludos.

Al compilar con fwh20.06, xHarbour 1.2.3. para bcc7.4, y bcc 7.4 me carca en algunas funciones el mensaje:

static function Nx() defined but never used

Como podria resolver este error?

Gracias

Noé Aburto Sánchez
Tec. Prog. de Sistemas. -Morelia, Mich. México.
fwh 20.06, Harbour 3.2.0, bcc 7.4
TsBrowse 9.0, TsButton 7.0, xEdit 6.1
naburtos@gmail.com, noeaburto67@hotmail.com
Posts: 1364
Joined: Wed Jun 21, 2006 12:39 AM
Re: static function XXX defined but never used?
Posted: Tue Aug 11, 2020 10:08 PM

Hola, ese mensaje te está indicando que hay una función definida y nunca es invocada, tendrías que ajustar los warnings de xHarbour y si no elimina las funciones que no uses.

Saludos

Posts: 8523
Joined: Tue Dec 20, 2005 07:36 PM
Re: static function XXX defined but never used?
Posted: Tue Aug 11, 2020 11:42 PM
Como compilas?

Code (fw): Select all Collapse
REM xHarbour
%hdir%\bin\harbour PROPOSTA /m/n /i%fwhdir%\include;%hdir%\include;%bcdir%\include /w0 /p     >> Erro.log 2>> ERROS.LOG

REM BCC74
%bcdir%\bin\bcc32 -M -c -v -O2 -ePROPOSTA.Exe -I%hdir%\include -I%bcdir%\include PROPOSTA.C   >> Erro.log 2>> ERROS.LOG


Saludos
João Santos - São Paulo - Brasil - Phone: +55(11)95150-7341
Posts: 10733
Joined: Sun Nov 19, 2006 05:22 AM
Re: static function XXX defined but never used?
Posted: Wed Aug 12, 2020 04:26 AM

xHarbour generates warning in such cases, but not Harbour.

Regards



G. N. Rao.

Hyderabad, India
Posts: 9022
Joined: Thu Oct 06, 2005 08:17 PM
Re: static function XXX defined but never used?
Posted: Wed Aug 12, 2020 03:39 PM
This is not true:

Code (fw): Select all Collapse
xHarbour 1.2.3 Intl. (SimpLex) (Build 20200311)
Copyright 1999-2020, http://www.xharbour.org <!-- m --><a class="postlink" href="http://www.harbour-project.org/">http://www.harbour-project.org/</a><!-- m -->
test.prg(10) Warning W0030  STATIC Function 'TEST' defined but never used


Code (fw): Select all Collapse
Harbour 3.2.0dev (r2002240732)
Copyright (c) 1999-2020, https://harbour.github.io/
test.prg(10) Warning W0034  STATIC Function 'TEST' defined but never used


Anyway, in both cases the EXE is properly build.

EMG

Continue the discussion