编译C程序时出错

时间:2016-09-25 14:43:42

标签: c windows gcc compiler-errors

我在学校学习C,我们必须创建一个管理音乐专辑矢量的程序,我尝试编译但是我有这个错误,我找不到有关的信息,编译错误是: “在get_parm_info中,在c-decl.c:4637”。

我该怎么办?

这只是一条信息。

代码太长而不适合那里,但除此之外没有其他错误。

    #include <stdlib.h>
#include <stdio.h>
#include <string.h>
#define MAX_STR 50
#define MAX_CANZONI 20
#define ALBUM_SIZE 44
struct t_canzone { //54 bytes   
    char titolo[MAX_STR];
    int durata; //In secondi
};
struct t_autore { //104 bytes
    char nome[MAX_STR];
    char cognome[MAX_STR];  
    int eta;
};
struct t_album {
    struct t_autore autore; //104 bytes
    char titolo[MAX_STR];   //50 bytes
    int numCanzoni;         //4 bytes
    struct t_canzone canzoni[MAX_CANZONI]; //1080 bytes
};    

void inizializzazione(struct t_album album);
void stampacompleta(struct t_album album);
void stampaalbum(struct t_album album,char nome[]);
void cercacanzone(struct t_album album, char nome[]);
void modificaalbum(struct t_album album, char nome[]);
void aggiungicanzone(struct t_album album, char nome[]);
void ordinamento(struct t_album album,void confronto(struct t_album,int,int);
void crescente(struct t_album album,int i,int z);
void decrescente(struct t_album album,int i,int z);
void titlesort(struct t_album album,int i,int z);
void namesort(struct t_album album,int i,int z);

void crescente(struct t_album album,int i,int z){
    struct t_album supporto;
    if(album[i].numCanzoni>album[z].numCanzoni)
    {
        supporto=album[i];
        album[i]=album[z];
        album[z]=supporto;
    }
}

void decrescente(struct t_album album,int i,int z){
    struct t_album supporto;
    if(album[i].numCanzoni<album[z].numCanzoni)
    {
        supporto=album[i];
        album[i]=album[z];
        album[z]=supporto;
    }
}

void titlesort(struct t_album album,int i,int z){
    if(strncmp(album[i].titolo,album[z].titolo)>0)
    {
        supporto=album[i];
        album[i]=album[z];
        album[z]=supporto;
    }
}

void namesort(struct t_album album,int i,int z){
    if(strncmp(album[i].autore.nome,album[z].autore.nome)>0)
    {
        supporto=album[i];
        album[i]=album[z];
        album[z]=supporto;
    }
    else if(strncmp(album[i].autore.nome,album[z].autore.nome)==0)
    {
        if(strncmp(album[i].autore.cognome,album[z].autore.cognome)>0)
        {
            supporto=album[i];
            album[i]=album[z];
            album[z]=supporto;
        }
    }
}  



void ordinamento(struct t_album album,void confronto(struct t_album,int,int){
    int i,z;
    for(i=0;i<ALBUM_SIZE-1;i++)
    {
        for(z=i+1;z<ALBUM_SIZE;z++)
        {
            confronto(album[],i,z);
        }
    }
}             

[评论更新:]

完整的“错误”消息是:

Compiler: Default compiler Executing gcc.exe... gcc.exe "C:\Users\lavpreet\Desktop\canzone.c" -o "C:\Users\lavpreet\Desktop\canzone.exe" -g3 -I"C:\Dev-Cpp\include" -L"C:\Dev-Cpp\lib" -g3 C:\Users\lavpreet\Desktop\canzone.c:35: internal compiler error: in get_parm_info, at c-decl.c:4637 
Please submit a full bug report, with preprocessed source if appropriate. See <URL:http://www.mingw.org/bugs.shtml> for instructions. Execution terminated 

1 个答案:

答案 0 :(得分:0)

这一行:

from splinter import Browser
url = "http://arashiyan.ir/Narm/entekhab.html"
browser=Browser('firefox')
browser.visit(url)
second_found = browser.find_by_name("LsnGrp[]")[3]
second_found.fill("3")

缺少尾随void ordinamento( struct t_album album, void confronto(struct t_album, int, int);

也是这一行:

)

缺少尾随void ordinamento(struct t_album album,void confronto(struct t_album,int,int){